diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-08-05 13:08:42 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-08-05 13:08:42 +0200 |
commit | 5c99acb7dafee2c2d80a4250327086227310c375 (patch) | |
tree | 1be65672e628dad0fb1f99922a88a35ecf1a769f | |
parent | 22d841becd89f21fcd88a76bcafb675fd051ce86 (diff) | |
download | ffmpeg-5c99acb7dafee2c2d80a4250327086227310c375.tar.gz |
Revert "lavfi: add audio channel packing negotiation fields"
This reverts commit b57df29f95d1107a66315a6744c1c3e73293b2ee.
Conflicts:
doc/APIchanges
libavfilter/avfilter.h
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | doc/APIchanges | 8 | ||||
-rw-r--r-- | libavfilter/avfilter.c | 3 | ||||
-rw-r--r-- | libavfilter/avfilter.h | 16 | ||||
-rw-r--r-- | libavfilter/avfiltergraph.c | 6 | ||||
-rw-r--r-- | libavfilter/defaults.c | 8 | ||||
-rw-r--r-- | libavfilter/formats.c | 11 |
6 files changed, 2 insertions, 50 deletions
diff --git a/doc/APIchanges b/doc/APIchanges index eba7f8416b..5c5a8fd430 100644 --- a/doc/APIchanges +++ b/doc/APIchanges @@ -16,14 +16,6 @@ API changes, most recent first: 2011-08-02 - 9d39cbf - lavc 53.7.1 Add AV_PKT_FLAG_CORRUPT AVPacket flag. -2011-07-16 - xxxxxx - lavfi 2.27.0 - Add audio packing negotiation fields and helper functions. - - In particular, add AVFilterPacking enum, planar, in_packings and - out_packings fields to AVFilterLink, and the functions: - avfilter_set_common_packing_formats() - avfilter_all_packing_formats() - 2011-07-10 - a67c061 - lavf 53.3.0 Add avformat_find_stream_info(), deprecate av_find_stream_info(). diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c index 7003cdda5c..a57677c0e4 100644 --- a/libavfilter/avfilter.c +++ b/libavfilter/avfilter.c @@ -221,9 +221,6 @@ int avfilter_insert_filter(AVFilterLink *link, AVFilterContext *filt, if (link->out_chlayouts) avfilter_formats_changeref(&link->out_chlayouts, &filt->outputs[filt_dstpad_idx]->out_chlayouts); - if (link->out_packing) - avfilter_formats_changeref(&link->out_packing, - &filt->outputs[filt_dstpad_idx]->out_packing); return 0; } diff --git a/libavfilter/avfilter.h b/libavfilter/avfilter.h index 0cbc3f7415..434bc60289 100644 --- a/libavfilter/avfilter.h +++ b/libavfilter/avfilter.h @@ -265,11 +265,6 @@ AVFilterFormats *avfilter_all_formats(enum AVMediaType type); AVFilterFormats *avfilter_all_channel_layouts(void); /** - * Return a list of all audio packing formats. - */ -AVFilterFormats *avfilter_all_packing_formats(void); - -/** * Return a format list which contains the intersection of the formats of * a and b. Also, all the references of a, all the references of b, and * a and b themselves will be deallocated. @@ -487,7 +482,6 @@ AVFilterBufferRef *avfilter_default_get_audio_buffer(AVFilterLink *link, int per void avfilter_set_common_pixel_formats(AVFilterContext *ctx, AVFilterFormats *formats); void avfilter_set_common_sample_formats(AVFilterContext *ctx, AVFilterFormats *formats); void avfilter_set_common_channel_layouts(AVFilterContext *ctx, AVFilterFormats *formats); -void avfilter_set_common_packing_formats(AVFilterContext *ctx, AVFilterFormats *formats); /** Default handler for query_formats() */ int avfilter_default_query_formats(AVFilterContext *ctx); @@ -576,11 +570,6 @@ struct AVFilterContext { void *priv; ///< private data for use by the filter }; -enum AVFilterPacking { - AVFILTER_PACKED = 0, - AVFILTER_PLANAR, -}; - /** * A link between two filters. This contains pointers to the source and * destination filters between which this link exists, and the indexes of @@ -608,10 +597,9 @@ struct AVFilterLink { int w; ///< agreed upon image width int h; ///< agreed upon image height AVRational sample_aspect_ratio; ///< agreed upon sample aspect ratio - /* These parameters apply only to audio */ + /* These two parameters apply only to audio */ int64_t channel_layout; ///< channel layout of current buffer (see libavutil/audioconvert.h) int64_t sample_rate; ///< samples per second - int planar; ///< agreed upon packing mode of audio buffers. true if planar. int format; ///< agreed upon media format @@ -627,8 +615,6 @@ struct AVFilterLink { AVFilterFormats *in_chlayouts; AVFilterFormats *out_chlayouts; - AVFilterFormats *in_packing; - AVFilterFormats *out_packing; /** * The buffer reference currently being sent across the link by the source diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c index 8756e42bd4..04768617de 100644 --- a/libavfilter/avfiltergraph.c +++ b/libavfilter/avfiltergraph.c @@ -203,12 +203,8 @@ static void pick_format(AVFilterLink *link) link->channel_layout = link->in_chlayouts->formats[0]; avfilter_formats_unref(&link->in_chlayouts); avfilter_formats_unref(&link->out_chlayouts); - - link->in_packing->format_count = 1; - link->planar = link->in_packing->formats[0] == AVFILTER_PLANAR; - avfilter_formats_unref(&link->in_packing); - avfilter_formats_unref(&link->out_packing); } + } static void pick_formats(AVFilterGraph *graph) diff --git a/libavfilter/defaults.c b/libavfilter/defaults.c index eef9fd1278..b03816dd24 100644 --- a/libavfilter/defaults.c +++ b/libavfilter/defaults.c @@ -239,19 +239,11 @@ void avfilter_set_common_channel_layouts(AVFilterContext *ctx, AVFilterFormats * offsetof(AVFilterLink, out_chlayouts)); } -void avfilter_set_common_packing_formats(AVFilterContext *ctx, AVFilterFormats *formats) -{ - set_common_formats(ctx, formats, AVMEDIA_TYPE_AUDIO, - offsetof(AVFilterLink, in_packing), - offsetof(AVFilterLink, out_packing)); -} - int avfilter_default_query_formats(AVFilterContext *ctx) { avfilter_set_common_pixel_formats(ctx, avfilter_all_formats(AVMEDIA_TYPE_VIDEO)); avfilter_set_common_sample_formats(ctx, avfilter_all_formats(AVMEDIA_TYPE_AUDIO)); avfilter_set_common_channel_layouts(ctx, avfilter_all_channel_layouts()); - avfilter_set_common_packing_formats(ctx, avfilter_all_packing_formats()); return 0; } diff --git a/libavfilter/formats.c b/libavfilter/formats.c index 214718b779..b6e30e7ab4 100644 --- a/libavfilter/formats.c +++ b/libavfilter/formats.c @@ -173,17 +173,6 @@ AVFilterFormats *avfilter_all_channel_layouts(void) return avfilter_make_format64_list(chlayouts); } -AVFilterFormats *avfilter_all_packing_formats(void) -{ - static int packing[] = { - AVFILTER_PACKED, - AVFILTER_PLANAR, - -1, - }; - - return avfilter_make_format_list(packing); -} - void avfilter_formats_ref(AVFilterFormats *f, AVFilterFormats **ref) { *ref = f; |