From 0177b7d23aadeab218601893953f0a05209d037c Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Tue, 24 Jul 2012 03:23:48 +0200 Subject: Improve descriptiveness of a number of codec and container long names --- libavcodec/aacdec.c | 2 +- libavcodec/aacenc.c | 2 +- libavcodec/amrnbdec.c | 2 +- libavcodec/amrwbdec.c | 2 +- libavcodec/assdec.c | 2 +- libavcodec/assenc.c | 2 +- libavcodec/bmp.c | 2 +- libavcodec/bmpenc.c | 2 +- libavcodec/cavsdec.c | 2 +- libavcodec/cook.c | 2 +- libavcodec/flvdec.c | 2 +- libavcodec/flvenc.c | 2 +- libavcodec/libfaac.c | 2 +- libavcodec/libilbc.c | 4 ++-- libavcodec/libopencore-amr.c | 6 +++--- libavcodec/libopenjpegdec.c | 2 +- libavcodec/libvo-aacenc.c | 2 +- libavcodec/libvo-amrwbenc.c | 4 ++-- libavcodec/libxavs.c | 2 +- libavcodec/tta.c | 2 +- libavdevice/oss_audio.c | 4 ++-- libavformat/aacdec.c | 2 +- libavformat/adtsenc.c | 2 +- libavformat/asfdec.c | 2 +- libavformat/asfenc.c | 4 ++-- libavformat/assdec.c | 2 +- libavformat/assenc.c | 2 +- libavformat/au.c | 4 ++-- libavformat/avidec.c | 2 +- libavformat/avienc.c | 2 +- libavformat/cafdec.c | 2 +- libavformat/cavsvideodec.c | 2 +- libavformat/dv.c | 2 +- libavformat/dvenc.c | 2 +- libavformat/flvdec.c | 2 +- libavformat/flvenc.c | 2 +- libavformat/gxf.c | 2 +- libavformat/gxfenc.c | 2 +- libavformat/iff.c | 2 +- libavformat/iv8.c | 2 +- libavformat/mov.c | 2 +- libavformat/movenc.c | 12 ++++++------ libavformat/mp3dec.c | 2 +- libavformat/mp3enc.c | 4 ++-- libavformat/mpeg.c | 2 +- libavformat/mpegenc.c | 6 +++--- libavformat/mpegts.c | 4 ++-- libavformat/mpegtsenc.c | 2 +- libavformat/mxfdec.c | 2 +- libavformat/mxfenc.c | 4 ++-- libavformat/rawenc.c | 2 +- libavformat/segment.c | 2 +- libavformat/swfdec.c | 2 +- libavformat/swfenc.c | 4 ++-- libavformat/tta.c | 2 +- libavformat/wav.c | 4 ++-- 56 files changed, 75 insertions(+), 75 deletions(-) diff --git a/libavcodec/aacdec.c b/libavcodec/aacdec.c index 76d4120a41..c57304447c 100644 --- a/libavcodec/aacdec.c +++ b/libavcodec/aacdec.c @@ -2867,7 +2867,7 @@ AVCodec ff_aac_latm_decoder = { .init = latm_decode_init, .close = aac_decode_close, .decode = latm_decode_frame, - .long_name = NULL_IF_CONFIG_SMALL("AAC LATM (Advanced Audio Codec LATM syntax)"), + .long_name = NULL_IF_CONFIG_SMALL("AAC LATM (Advanced Audio Coding LATM syntax)"), .sample_fmts = (const enum AVSampleFormat[]) { AV_SAMPLE_FMT_FLT, AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, diff --git a/libavcodec/aacenc.c b/libavcodec/aacenc.c index 0186011136..f7360a1785 100644 --- a/libavcodec/aacenc.c +++ b/libavcodec/aacenc.c @@ -828,6 +828,6 @@ AVCodec ff_aac_encoder = { CODEC_CAP_EXPERIMENTAL, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_FLT, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("Advanced Audio Coding"), + .long_name = NULL_IF_CONFIG_SMALL("AAC (Advanced Audio Coding)"), .priv_class = &aacenc_class, }; diff --git a/libavcodec/amrnbdec.c b/libavcodec/amrnbdec.c index ab721ea239..27f5eac1c5 100644 --- a/libavcodec/amrnbdec.c +++ b/libavcodec/amrnbdec.c @@ -1062,7 +1062,7 @@ AVCodec ff_amrnb_decoder = { .init = amrnb_decode_init, .decode = amrnb_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("Adaptive Multi-Rate NarrowBand"), + .long_name = NULL_IF_CONFIG_SMALL("AMR-NB (Adaptive Multi-Rate NarrowBand)"), .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_FLT, AV_SAMPLE_FMT_NONE }, }; diff --git a/libavcodec/amrwbdec.c b/libavcodec/amrwbdec.c index ed60529504..c1b577ace2 100644 --- a/libavcodec/amrwbdec.c +++ b/libavcodec/amrwbdec.c @@ -1242,7 +1242,7 @@ AVCodec ff_amrwb_decoder = { .init = amrwb_decode_init, .decode = amrwb_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("Adaptive Multi-Rate WideBand"), + .long_name = NULL_IF_CONFIG_SMALL("AMR-WB (Adaptive Multi-Rate WideBand)"), .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_FLT, AV_SAMPLE_FMT_NONE }, }; diff --git a/libavcodec/assdec.c b/libavcodec/assdec.c index 98f7be36a2..2d82ca6ef7 100644 --- a/libavcodec/assdec.c +++ b/libavcodec/assdec.c @@ -54,7 +54,7 @@ static int ass_decode_frame(AVCodecContext *avctx, void *data, int *got_sub_ptr, AVCodec ff_ass_decoder = { .name = "ass", - .long_name = NULL_IF_CONFIG_SMALL("Advanced SubStation Alpha subtitle"), + .long_name = NULL_IF_CONFIG_SMALL("SSA (SubStation Alpha) subtitle"), .type = AVMEDIA_TYPE_SUBTITLE, .id = CODEC_ID_SSA, .init = ass_decode_init, diff --git a/libavcodec/assenc.c b/libavcodec/assenc.c index b7836ff29f..1e442c88c9 100644 --- a/libavcodec/assenc.c +++ b/libavcodec/assenc.c @@ -59,7 +59,7 @@ static int ass_encode_frame(AVCodecContext *avctx, AVCodec ff_ass_encoder = { .name = "ass", - .long_name = NULL_IF_CONFIG_SMALL("Advanced SubStation Alpha subtitle"), + .long_name = NULL_IF_CONFIG_SMALL("SSA (SubStation Alpha) subtitle"), .type = AVMEDIA_TYPE_SUBTITLE, .id = CODEC_ID_SSA, .init = ass_encode_init, diff --git a/libavcodec/bmp.c b/libavcodec/bmp.c index df947a0745..210d012aaa 100644 --- a/libavcodec/bmp.c +++ b/libavcodec/bmp.c @@ -370,5 +370,5 @@ AVCodec ff_bmp_decoder = { .close = bmp_decode_end, .decode = bmp_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("BMP image"), + .long_name = NULL_IF_CONFIG_SMALL("BMP (Windows and OS/2 bitmap)"), }; diff --git a/libavcodec/bmpenc.c b/libavcodec/bmpenc.c index 6d24cacb1c..e1872122c7 100644 --- a/libavcodec/bmpenc.c +++ b/libavcodec/bmpenc.c @@ -173,5 +173,5 @@ AVCodec ff_bmp_encoder = { PIX_FMT_MONOBLACK, PIX_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("BMP image"), + .long_name = NULL_IF_CONFIG_SMALL("BMP (Windows and OS/2 bitmap)"), }; diff --git a/libavcodec/cavsdec.c b/libavcodec/cavsdec.c index 9f91d0b8ca..30a69b6fb0 100644 --- a/libavcodec/cavsdec.c +++ b/libavcodec/cavsdec.c @@ -725,5 +725,5 @@ AVCodec ff_cavs_decoder = { .decode = cavs_decode_frame, .capabilities = CODEC_CAP_DR1 | CODEC_CAP_DELAY, .flush = cavs_flush, - .long_name = NULL_IF_CONFIG_SMALL("Chinese AVS video (AVS1-P2, JiZhun profile)"), + .long_name = NULL_IF_CONFIG_SMALL("Chinese AVS (Audio Video Standard) (AVS1-P2, JiZhun profile)"), }; diff --git a/libavcodec/cook.c b/libavcodec/cook.c index c8d7d77839..5b1f9d561e 100644 --- a/libavcodec/cook.c +++ b/libavcodec/cook.c @@ -1303,5 +1303,5 @@ AVCodec ff_cook_decoder = { .close = cook_decode_close, .decode = cook_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("COOK"), + .long_name = NULL_IF_CONFIG_SMALL("Cook / Cooker / Gecko (RealAudio G2)"), }; diff --git a/libavcodec/flvdec.c b/libavcodec/flvdec.c index fa074c4083..f7a512b435 100644 --- a/libavcodec/flvdec.c +++ b/libavcodec/flvdec.c @@ -127,6 +127,6 @@ AVCodec ff_flv_decoder = { .close = ff_h263_decode_end, .decode = ff_h263_decode_frame, .capabilities = CODEC_CAP_DRAW_HORIZ_BAND | CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("Flash Video (FLV) / Sorenson Spark / Sorenson H.263"), + .long_name = NULL_IF_CONFIG_SMALL("FLV / Sorenson Spark / Sorenson H.263 (Flash Video)"), .pix_fmts = ff_pixfmt_list_420, }; diff --git a/libavcodec/flvenc.c b/libavcodec/flvenc.c index b5dfd66898..b793bd7978 100644 --- a/libavcodec/flvenc.c +++ b/libavcodec/flvenc.c @@ -95,6 +95,6 @@ AVCodec ff_flv_encoder = { .encode2 = ff_MPV_encode_picture, .close = ff_MPV_encode_end, .pix_fmts = (const enum PixelFormat[]){ PIX_FMT_YUV420P, PIX_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("Flash Video (FLV) / Sorenson Spark / Sorenson H.263"), + .long_name = NULL_IF_CONFIG_SMALL("FLV / Sorenson Spark / Sorenson H.263 (Flash Video)"), .priv_class = &flv_class, }; diff --git a/libavcodec/libfaac.c b/libavcodec/libfaac.c index e18e133bc7..50860f2967 100644 --- a/libavcodec/libfaac.c +++ b/libavcodec/libfaac.c @@ -246,7 +246,7 @@ AVCodec ff_libfaac_encoder = { .capabilities = CODEC_CAP_SMALL_LAST_FRAME | CODEC_CAP_DELAY, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("libfaac AAC (Advanced Audio Codec)"), + .long_name = NULL_IF_CONFIG_SMALL("libfaac AAC (Advanced Audio Coding)"), .profiles = NULL_IF_CONFIG_SMALL(profiles), .channel_layouts = faac_channel_layouts, }; diff --git a/libavcodec/libilbc.c b/libavcodec/libilbc.c index 1c056d5cd7..5179c375b2 100644 --- a/libavcodec/libilbc.c +++ b/libavcodec/libilbc.c @@ -111,7 +111,7 @@ AVCodec ff_libilbc_decoder = { .init = ilbc_decode_init, .decode = ilbc_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("Internet Low Bitrate Codec (iLBC)"), + .long_name = NULL_IF_CONFIG_SMALL("iLBC (Internet Low Bitrate Codec)"), .priv_class = &ilbc_dec_class, }; @@ -203,7 +203,7 @@ AVCodec ff_libilbc_encoder = { .close = ilbc_encode_close, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("Internet Low Bitrate Codec (iLBC)"), + .long_name = NULL_IF_CONFIG_SMALL("iLBC (Internet Low Bitrate Codec)"), .defaults = ilbc_encode_defaults, .priv_class = &ilbc_enc_class, }; diff --git a/libavcodec/libopencore-amr.c b/libavcodec/libopencore-amr.c index 35feca5369..61bfcc0398 100644 --- a/libavcodec/libopencore-amr.c +++ b/libavcodec/libopencore-amr.c @@ -180,7 +180,7 @@ AVCodec ff_libopencore_amrnb_decoder = { .close = amr_nb_decode_close, .decode = amr_nb_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("OpenCORE Adaptive Multi-Rate (AMR) Narrow-Band"), + .long_name = NULL_IF_CONFIG_SMALL("OpenCORE AMR-NB (Adaptive Multi-Rate Narrow-Band)"), }; static av_cold int amr_nb_encode_init(AVCodecContext *avctx) @@ -299,7 +299,7 @@ AVCodec ff_libopencore_amrnb_encoder = { .capabilities = CODEC_CAP_DELAY | CODEC_CAP_SMALL_LAST_FRAME, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("OpenCORE Adaptive Multi-Rate (AMR) Narrow-Band"), + .long_name = NULL_IF_CONFIG_SMALL("OpenCORE AMR-NB (Adaptive Multi-Rate Narrow-Band)"), .priv_class = &class, }; @@ -386,7 +386,7 @@ AVCodec ff_libopencore_amrwb_decoder = { .close = amr_wb_decode_close, .decode = amr_wb_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("OpenCORE Adaptive Multi-Rate (AMR) Wide-Band"), + .long_name = NULL_IF_CONFIG_SMALL("OpenCORE AMR-WB (Adaptive Multi-Rate Wide-Band)"), }; #endif /* CONFIG_LIBOPENCORE_AMRWB */ diff --git a/libavcodec/libopenjpegdec.c b/libavcodec/libopenjpegdec.c index c84a9aca03..ed6b141cba 100644 --- a/libavcodec/libopenjpegdec.c +++ b/libavcodec/libopenjpegdec.c @@ -452,7 +452,7 @@ AVCodec ff_libopenjpeg_decoder = { .close = libopenjpeg_decode_close, .decode = libopenjpeg_decode_frame, .capabilities = CODEC_CAP_DR1 | CODEC_CAP_FRAME_THREADS, - .long_name = NULL_IF_CONFIG_SMALL("OpenJPEG based JPEG 2000 decoder"), + .long_name = NULL_IF_CONFIG_SMALL("OpenJPEG JPEG 2000"), .priv_class = &class, .init_thread_copy = ONLY_IF_THREADS_ENABLED(libopenjpeg_decode_init_thread_copy), }; diff --git a/libavcodec/libvo-aacenc.c b/libavcodec/libvo-aacenc.c index 66ef5cdf2b..44bad97f33 100644 --- a/libavcodec/libvo-aacenc.c +++ b/libavcodec/libvo-aacenc.c @@ -198,5 +198,5 @@ AVCodec ff_libvo_aacenc_encoder = { .capabilities = CODEC_CAP_SMALL_LAST_FRAME | CODEC_CAP_DELAY, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("Android VisualOn AAC"), + .long_name = NULL_IF_CONFIG_SMALL("Android VisualOn AAC (Advanced Audio Coding)"), }; diff --git a/libavcodec/libvo-amrwbenc.c b/libavcodec/libvo-amrwbenc.c index fb712a8edd..0e5ee75096 100644 --- a/libavcodec/libvo-amrwbenc.c +++ b/libavcodec/libvo-amrwbenc.c @@ -150,7 +150,7 @@ AVCodec ff_libvo_amrwbenc_encoder = { .close = amr_wb_encode_close, .sample_fmts = (const enum AVSampleFormat[]){ AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("Android VisualOn Adaptive " - "Multi-Rate (AMR) Wide-Band"), + .long_name = NULL_IF_CONFIG_SMALL("Android VisualOn AMR-WB " + "(Adaptive Multi-Rate Wide-Band)"), .priv_class = &class, }; diff --git a/libavcodec/libxavs.c b/libavcodec/libxavs.c index 9e45a3796b..4713d75a79 100644 --- a/libavcodec/libxavs.c +++ b/libavcodec/libxavs.c @@ -426,7 +426,7 @@ AVCodec ff_libxavs_encoder = { .close = XAVS_close, .capabilities = CODEC_CAP_DELAY | CODEC_CAP_AUTO_THREADS, .pix_fmts = (const enum PixelFormat[]) { PIX_FMT_YUV420P, PIX_FMT_NONE }, - .long_name = NULL_IF_CONFIG_SMALL("libxavs - the Chinese Audio Video Standard Encoder"), + .long_name = NULL_IF_CONFIG_SMALL("libxavs Chinese AVS (Audio Video Standard)"), .priv_class = &class, .defaults = xavs_defaults, }; diff --git a/libavcodec/tta.c b/libavcodec/tta.c index 0650086dcd..5590ae28a1 100644 --- a/libavcodec/tta.c +++ b/libavcodec/tta.c @@ -475,5 +475,5 @@ AVCodec ff_tta_decoder = { .close = tta_decode_close, .decode = tta_decode_frame, .capabilities = CODEC_CAP_DR1, - .long_name = NULL_IF_CONFIG_SMALL("True Audio (TTA)"), + .long_name = NULL_IF_CONFIG_SMALL("TTA (True Audio)"), }; diff --git a/libavdevice/oss_audio.c b/libavdevice/oss_audio.c index b5fbb318dc..ef0ace94f0 100644 --- a/libavdevice/oss_audio.c +++ b/libavdevice/oss_audio.c @@ -296,7 +296,7 @@ static const AVClass oss_demuxer_class = { AVInputFormat ff_oss_demuxer = { .name = "oss", - .long_name = NULL_IF_CONFIG_SMALL("Open Sound System capture"), + .long_name = NULL_IF_CONFIG_SMALL("OSS (Open Sound System) capture"), .priv_data_size = sizeof(AudioData), .read_header = audio_read_header, .read_packet = audio_read_packet, @@ -309,7 +309,7 @@ AVInputFormat ff_oss_demuxer = { #if CONFIG_OSS_OUTDEV AVOutputFormat ff_oss_muxer = { .name = "oss", - .long_name = NULL_IF_CONFIG_SMALL("Open Sound System playback"), + .long_name = NULL_IF_CONFIG_SMALL("OSS (Open Sound System) playback"), .priv_data_size = sizeof(AudioData), /* XXX: we make the assumption that the soundcard accepts this format */ /* XXX: find better solution with "preinit" method, needed also in diff --git a/libavformat/aacdec.c b/libavformat/aacdec.c index 2aedd5d1d7..df6855526b 100644 --- a/libavformat/aacdec.c +++ b/libavformat/aacdec.c @@ -83,7 +83,7 @@ static int adts_aac_read_header(AVFormatContext *s) AVInputFormat ff_aac_demuxer = { .name = "aac", - .long_name = NULL_IF_CONFIG_SMALL("raw ADTS AAC"), + .long_name = NULL_IF_CONFIG_SMALL("raw ADTS AAC (Advanced Audio Coding)"), .read_probe = adts_aac_probe, .read_header = adts_aac_read_header, .read_packet = ff_raw_read_partial_packet, diff --git a/libavformat/adtsenc.c b/libavformat/adtsenc.c index 1a9f879aac..e08eef5e5c 100644 --- a/libavformat/adtsenc.c +++ b/libavformat/adtsenc.c @@ -165,7 +165,7 @@ static int adts_write_packet(AVFormatContext *s, AVPacket *pkt) AVOutputFormat ff_adts_muxer = { .name = "adts", - .long_name = NULL_IF_CONFIG_SMALL("ADTS AAC"), + .long_name = NULL_IF_CONFIG_SMALL("ADTS AAC (Advanced Audio Coding)"), .mime_type = "audio/aac", .extensions = "aac,adts", .priv_data_size = sizeof(ADTSContext), diff --git a/libavformat/asfdec.c b/libavformat/asfdec.c index 91b099208e..a0bbdb420e 100644 --- a/libavformat/asfdec.c +++ b/libavformat/asfdec.c @@ -1401,7 +1401,7 @@ static int asf_read_seek(AVFormatContext *s, int stream_index, int64_t pts, int AVInputFormat ff_asf_demuxer = { .name = "asf", - .long_name = NULL_IF_CONFIG_SMALL("ASF format"), + .long_name = NULL_IF_CONFIG_SMALL("ASF (Advanced / Active Streaming Format)"), .priv_data_size = sizeof(ASFContext), .read_probe = asf_probe, .read_header = asf_read_header, diff --git a/libavformat/asfenc.c b/libavformat/asfenc.c index a8814eba53..9ac395382d 100644 --- a/libavformat/asfenc.c +++ b/libavformat/asfenc.c @@ -880,7 +880,7 @@ static int asf_write_trailer(AVFormatContext *s) #if CONFIG_ASF_MUXER AVOutputFormat ff_asf_muxer = { .name = "asf", - .long_name = NULL_IF_CONFIG_SMALL("ASF format"), + .long_name = NULL_IF_CONFIG_SMALL("ASF (Advanced / Active Streaming Format)"), .mime_type = "video/x-ms-asf", .extensions = "asf,wmv,wma", .priv_data_size = sizeof(ASFContext), @@ -899,7 +899,7 @@ AVOutputFormat ff_asf_muxer = { #if CONFIG_ASF_STREAM_MUXER AVOutputFormat ff_asf_stream_muxer = { .name = "asf_stream", - .long_name = NULL_IF_CONFIG_SMALL("ASF format"), + .long_name = NULL_IF_CONFIG_SMALL("ASF (Advanced / Active Streaming Format)"), .mime_type = "video/x-ms-asf", .extensions = "asf,wmv,wma", .priv_data_size = sizeof(ASFContext), diff --git a/libavformat/assdec.c b/libavformat/assdec.c index bb85f29304..116c7ec681 100644 --- a/libavformat/assdec.c +++ b/libavformat/assdec.c @@ -205,7 +205,7 @@ static int read_seek2(AVFormatContext *s, int stream_index, AVInputFormat ff_ass_demuxer = { .name = "ass", - .long_name = NULL_IF_CONFIG_SMALL("Advanced SubStation Alpha subtitle"), + .long_name = NULL_IF_CONFIG_SMALL("SSA (SubStation Alpha) subtitle"), .priv_data_size = sizeof(ASSContext), .read_probe = probe, .read_header = read_header, diff --git a/libavformat/assenc.c b/libavformat/assenc.c index b3f422d8b9..dca8e8c0c5 100644 --- a/libavformat/assenc.c +++ b/libavformat/assenc.c @@ -79,7 +79,7 @@ static int write_trailer(AVFormatContext *s) AVOutputFormat ff_ass_muxer = { .name = "ass", - .long_name = NULL_IF_CONFIG_SMALL("Advanced SubStation Alpha subtitle"), + .long_name = NULL_IF_CONFIG_SMALL("SSA (SubStation Alpha) subtitle"), .mime_type = "text/x-ssa", .extensions = "ass,ssa", .priv_data_size = sizeof(ASSContext), diff --git a/libavformat/au.c b/libavformat/au.c index bb9d5d5b56..e88486bdcd 100644 --- a/libavformat/au.c +++ b/libavformat/au.c @@ -191,7 +191,7 @@ static int au_read_packet(AVFormatContext *s, #if CONFIG_AU_DEMUXER AVInputFormat ff_au_demuxer = { .name = "au", - .long_name = NULL_IF_CONFIG_SMALL("SUN AU format"), + .long_name = NULL_IF_CONFIG_SMALL("Sun AU"), .read_probe = au_probe, .read_header = au_read_header, .read_packet = au_read_packet, @@ -203,7 +203,7 @@ AVInputFormat ff_au_demuxer = { #if CONFIG_AU_MUXER AVOutputFormat ff_au_muxer = { .name = "au", - .long_name = NULL_IF_CONFIG_SMALL("SUN AU format"), + .long_name = NULL_IF_CONFIG_SMALL("Sun AU"), .mime_type = "audio/basic", .extensions = "au", .audio_codec = CODEC_ID_PCM_S16BE, diff --git a/libavformat/avidec.c b/libavformat/avidec.c index 38f84f9f94..60783ff2db 100644 --- a/libavformat/avidec.c +++ b/libavformat/avidec.c @@ -1393,7 +1393,7 @@ static int avi_probe(AVProbeData *p) AVInputFormat ff_avi_demuxer = { .name = "avi", - .long_name = NULL_IF_CONFIG_SMALL("AVI format"), + .long_name = NULL_IF_CONFIG_SMALL("AVI (Audio Video Interleaved)"), .priv_data_size = sizeof(AVIContext), .read_probe = avi_probe, .read_header = avi_read_header, diff --git a/libavformat/avienc.c b/libavformat/avienc.c index e611dcaae2..38c9d9d1e8 100644 --- a/libavformat/avienc.c +++ b/libavformat/avienc.c @@ -641,7 +641,7 @@ static int avi_write_trailer(AVFormatContext *s) AVOutputFormat ff_avi_muxer = { .name = "avi", - .long_name = NULL_IF_CONFIG_SMALL("AVI format"), + .long_name = NULL_IF_CONFIG_SMALL("AVI (Audio Video Interleaved)"), .mime_type = "video/x-msvideo", .extensions = "avi", .priv_data_size = sizeof(AVIContext), diff --git a/libavformat/cafdec.c b/libavformat/cafdec.c index b2eccb9d37..965ca5c91e 100644 --- a/libavformat/cafdec.c +++ b/libavformat/cafdec.c @@ -417,7 +417,7 @@ static int read_seek(AVFormatContext *s, int stream_index, AVInputFormat ff_caf_demuxer = { .name = "caf", - .long_name = NULL_IF_CONFIG_SMALL("Apple Core Audio Format"), + .long_name = NULL_IF_CONFIG_SMALL("Apple CAF (Core Audio Format)"), .priv_data_size = sizeof(CaffContext), .read_probe = probe, .read_header = read_header, diff --git a/libavformat/cavsvideodec.c b/libavformat/cavsvideodec.c index 9aa9413f4c..45323158bd 100644 --- a/libavformat/cavsvideodec.c +++ b/libavformat/cavsvideodec.c @@ -65,4 +65,4 @@ static int cavsvideo_probe(AVProbeData *p) return 0; } -FF_DEF_RAWVIDEO_DEMUXER(cavsvideo, "raw Chinese AVS video", cavsvideo_probe, NULL, CODEC_ID_CAVS) +FF_DEF_RAWVIDEO_DEMUXER(cavsvideo, "raw Chinese AVS (Audio Video Standard)", cavsvideo_probe, NULL, CODEC_ID_CAVS) diff --git a/libavformat/dv.c b/libavformat/dv.c index c71863a332..bd84d45c2f 100644 --- a/libavformat/dv.c +++ b/libavformat/dv.c @@ -536,7 +536,7 @@ static int dv_probe(AVProbeData *p) #if CONFIG_DV_DEMUXER AVInputFormat ff_dv_demuxer = { .name = "dv", - .long_name = NULL_IF_CONFIG_SMALL("DV video"), + .long_name = NULL_IF_CONFIG_SMALL("DV (Digital Video)"), .priv_data_size = sizeof(RawDVContext), .read_probe = dv_probe, .read_header = dv_read_header, diff --git a/libavformat/dvenc.c b/libavformat/dvenc.c index fdb259c3f1..848ca77ac0 100644 --- a/libavformat/dvenc.c +++ b/libavformat/dvenc.c @@ -405,7 +405,7 @@ static int dv_write_trailer(struct AVFormatContext *s) AVOutputFormat ff_dv_muxer = { .name = "dv", - .long_name = NULL_IF_CONFIG_SMALL("DV video"), + .long_name = NULL_IF_CONFIG_SMALL("DV (Digital Video)"), .extensions = "dv", .priv_data_size = sizeof(DVMuxContext), .audio_codec = CODEC_ID_PCM_S16LE, diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c index 3382454e0a..ee0a286421 100644 --- a/libavformat/flvdec.c +++ b/libavformat/flvdec.c @@ -875,7 +875,7 @@ static const AVClass class = { AVInputFormat ff_flv_demuxer = { .name = "flv", - .long_name = NULL_IF_CONFIG_SMALL("FLV format"), + .long_name = NULL_IF_CONFIG_SMALL("FLV (Flash Video)"), .priv_data_size = sizeof(FLVContext), .read_probe = flv_probe, .read_header = flv_read_header, diff --git a/libavformat/flvenc.c b/libavformat/flvenc.c index 2222085470..63d27836dd 100644 --- a/libavformat/flvenc.c +++ b/libavformat/flvenc.c @@ -542,7 +542,7 @@ static int flv_write_packet(AVFormatContext *s, AVPacket *pkt) AVOutputFormat ff_flv_muxer = { .name = "flv", - .long_name = NULL_IF_CONFIG_SMALL("FLV format"), + .long_name = NULL_IF_CONFIG_SMALL("FLV (Flash Video)"), .mime_type = "video/x-flv", .extensions = "flv", .priv_data_size = sizeof(FLVContext), diff --git a/libavformat/gxf.c b/libavformat/gxf.c index fcf6c93858..f47b6de24e 100644 --- a/libavformat/gxf.c +++ b/libavformat/gxf.c @@ -525,7 +525,7 @@ static int64_t gxf_read_timestamp(AVFormatContext *s, int stream_index, AVInputFormat ff_gxf_demuxer = { .name = "gxf", - .long_name = NULL_IF_CONFIG_SMALL("GXF format"), + .long_name = NULL_IF_CONFIG_SMALL("GXF (General eXchange Format)"), .priv_data_size = sizeof(struct gxf_stream_info), .read_probe = gxf_probe, .read_header = gxf_header, diff --git a/libavformat/gxfenc.c b/libavformat/gxfenc.c index c11b77bedc..7d5ccf874a 100644 --- a/libavformat/gxfenc.c +++ b/libavformat/gxfenc.c @@ -930,7 +930,7 @@ static int gxf_interleave_packet(AVFormatContext *s, AVPacket *out, AVPacket *pk AVOutputFormat ff_gxf_muxer = { .name = "gxf", - .long_name = NULL_IF_CONFIG_SMALL("GXF format"), + .long_name = NULL_IF_CONFIG_SMALL("GXF (General eXchange Format)"), .extensions = "gxf", .priv_data_size = sizeof(GXFContext), .audio_codec = CODEC_ID_PCM_S16LE, diff --git a/libavformat/iff.c b/libavformat/iff.c index cde420ea3e..596901586b 100644 --- a/libavformat/iff.c +++ b/libavformat/iff.c @@ -282,7 +282,7 @@ static int iff_read_packet(AVFormatContext *s, AVInputFormat ff_iff_demuxer = { .name = "iff", - .long_name = NULL_IF_CONFIG_SMALL("Interchange File Format"), + .long_name = NULL_IF_CONFIG_SMALL("IFF (Interchange File Format)"), .priv_data_size = sizeof(IffDemuxContext), .read_probe = iff_probe, .read_header = iff_read_header, diff --git a/libavformat/iv8.c b/libavformat/iv8.c index 4402855946..99732fc15d 100644 --- a/libavformat/iv8.c +++ b/libavformat/iv8.c @@ -110,7 +110,7 @@ static int read_packet(AVFormatContext *s, AVPacket *pkt) AVInputFormat ff_iv8_demuxer = { .name = "iv8", - .long_name = NULL_IF_CONFIG_SMALL("A format generated by IndigoVision 8000 video server"), + .long_name = NULL_IF_CONFIG_SMALL("IndigoVision 8000 video"), .read_probe = probe, .read_header = read_header, .read_packet = read_packet, diff --git a/libavformat/mov.c b/libavformat/mov.c index 95acccfc7a..785752455b 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -2892,7 +2892,7 @@ static int mov_read_seek(AVFormatContext *s, int stream_index, int64_t sample_ti AVInputFormat ff_mov_demuxer = { .name = "mov,mp4,m4a,3gp,3g2,mj2", - .long_name = NULL_IF_CONFIG_SMALL("QuickTime/MPEG-4/Motion JPEG 2000 format"), + .long_name = NULL_IF_CONFIG_SMALL("QuickTime / MOV"), .priv_data_size = sizeof(MOVContext), .read_probe = mov_probe, .read_header = mov_read_header, diff --git a/libavformat/movenc.c b/libavformat/movenc.c index 3778e6bee1..23c852e7aa 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -3248,7 +3248,7 @@ static int mov_write_trailer(AVFormatContext *s) MOV_CLASS(mov) AVOutputFormat ff_mov_muxer = { .name = "mov", - .long_name = NULL_IF_CONFIG_SMALL("MOV format"), + .long_name = NULL_IF_CONFIG_SMALL("QuickTime / MOV"), .extensions = "mov", .priv_data_size = sizeof(MOVMuxContext), .audio_codec = CODEC_ID_AAC, @@ -3268,7 +3268,7 @@ AVOutputFormat ff_mov_muxer = { MOV_CLASS(tgp) AVOutputFormat ff_tgp_muxer = { .name = "3gp", - .long_name = NULL_IF_CONFIG_SMALL("3GP format"), + .long_name = NULL_IF_CONFIG_SMALL("3GP (3GPP file format)"), .extensions = "3gp", .priv_data_size = sizeof(MOVMuxContext), .audio_codec = CODEC_ID_AMR_NB, @@ -3285,7 +3285,7 @@ AVOutputFormat ff_tgp_muxer = { MOV_CLASS(mp4) AVOutputFormat ff_mp4_muxer = { .name = "mp4", - .long_name = NULL_IF_CONFIG_SMALL("MP4 format"), + .long_name = NULL_IF_CONFIG_SMALL("MP4 (MPEG-4 Part 14)"), .mime_type = "application/mp4", .extensions = "mp4", .priv_data_size = sizeof(MOVMuxContext), @@ -3304,7 +3304,7 @@ AVOutputFormat ff_mp4_muxer = { MOV_CLASS(psp) AVOutputFormat ff_psp_muxer = { .name = "psp", - .long_name = NULL_IF_CONFIG_SMALL("PSP MP4 format"), + .long_name = NULL_IF_CONFIG_SMALL("PSP MP4 (MPEG-4 Part 14)"), .extensions = "mp4,psp", .priv_data_size = sizeof(MOVMuxContext), .audio_codec = CODEC_ID_AAC, @@ -3322,7 +3322,7 @@ AVOutputFormat ff_psp_muxer = { MOV_CLASS(tg2) AVOutputFormat ff_tg2_muxer = { .name = "3g2", - .long_name = NULL_IF_CONFIG_SMALL("3GP2 format"), + .long_name = NULL_IF_CONFIG_SMALL("3GP2 (3GPP2 file format)"), .extensions = "3g2", .priv_data_size = sizeof(MOVMuxContext), .audio_codec = CODEC_ID_AMR_NB, @@ -3339,7 +3339,7 @@ AVOutputFormat ff_tg2_muxer = { MOV_CLASS(ipod) AVOutputFormat ff_ipod_muxer = { .name = "ipod", - .long_name = NULL_IF_CONFIG_SMALL("iPod H.264 MP4 format"), + .long_name = NULL_IF_CONFIG_SMALL("iPod H.264 MP4 (MPEG-4 Part 14)"), .mime_type = "application/mp4", .extensions = "m4v,m4a", .priv_data_size = sizeof(MOVMuxContext), diff --git a/libavformat/mp3dec.c b/libavformat/mp3dec.c index a208488930..5976e33407 100644 --- a/libavformat/mp3dec.c +++ b/libavformat/mp3dec.c @@ -205,7 +205,7 @@ static int mp3_read_packet(AVFormatContext *s, AVPacket *pkt) AVInputFormat ff_mp3_demuxer = { .name = "mp3", - .long_name = NULL_IF_CONFIG_SMALL("MPEG audio layer 2/3"), + .long_name = NULL_IF_CONFIG_SMALL("MP2/3 (MPEG audio layer 2/3)"), .read_probe = mp3_read_probe, .read_header = mp3_read_header, .read_packet = mp3_read_packet, diff --git a/libavformat/mp3enc.c b/libavformat/mp3enc.c index 5365e3d505..af15d6a8c2 100644 --- a/libavformat/mp3enc.c +++ b/libavformat/mp3enc.c @@ -190,7 +190,7 @@ static int mp3_write_trailer(struct AVFormatContext *s) #if CONFIG_MP2_MUXER AVOutputFormat ff_mp2_muxer = { .name = "mp2", - .long_name = NULL_IF_CONFIG_SMALL("MPEG audio layer 2"), + .long_name = NULL_IF_CONFIG_SMALL("MP2 (MPEG audio layer 2)"), .mime_type = "audio/x-mpeg", .extensions = "mp2,m2a", .audio_codec = CODEC_ID_MP2, @@ -309,7 +309,7 @@ static int mp3_write_header(struct AVFormatContext *s) AVOutputFormat ff_mp3_muxer = { .name = "mp3", - .long_name = NULL_IF_CONFIG_SMALL("MPEG audio layer 3"), + .long_name = NULL_IF_CONFIG_SMALL("MP3 (MPEG audio layer 3)"), .mime_type = "audio/x-mpeg", .extensions = "mp3", .priv_data_size = sizeof(MP3Context), diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c index ebaf3dbdf2..a0b8f59576 100644 --- a/libavformat/mpeg.c +++ b/libavformat/mpeg.c @@ -567,7 +567,7 @@ static int64_t mpegps_read_dts(AVFormatContext *s, int stream_index, AVInputFormat ff_mpegps_demuxer = { .name = "mpeg", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-PS format"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-PS (MPEG-2 Program Stream)"), .priv_data_size = sizeof(MpegDemuxContext), .read_probe = mpegps_probe, .read_header = mpegps_read_header, diff --git a/libavformat/mpegenc.c b/libavformat/mpegenc.c index 4a1630b1a4..6144d6b66c 100644 --- a/libavformat/mpegenc.c +++ b/libavformat/mpegenc.c @@ -1144,7 +1144,7 @@ static const AVClass flavor ## _class = {\ MPEGENC_CLASS(mpeg) AVOutputFormat ff_mpeg1system_muxer = { .name = "mpeg", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-1 System format"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-1 Systems / MPEG program stream"), .mime_type = "video/mpeg", .extensions = "mpg,mpeg", .priv_data_size = sizeof(MpegMuxContext), @@ -1160,7 +1160,7 @@ AVOutputFormat ff_mpeg1system_muxer = { MPEGENC_CLASS(vcd) AVOutputFormat ff_mpeg1vcd_muxer = { .name = "vcd", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-1 System format (VCD)"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-1 Systems / MPEG program stream (VCD)"), .mime_type = "video/mpeg", .priv_data_size = sizeof(MpegMuxContext), .audio_codec = CODEC_ID_MP2, @@ -1193,7 +1193,7 @@ AVOutputFormat ff_mpeg2vob_muxer = { MPEGENC_CLASS(svcd) AVOutputFormat ff_mpeg2svcd_muxer = { .name = "svcd", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 PS format (VOB)"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 PS (SVCD)"), .mime_type = "video/mpeg", .extensions = "vob", .priv_data_size = sizeof(MpegMuxContext), diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c index 5b44c0e824..9bd18676ff 100644 --- a/libavformat/mpegts.c +++ b/libavformat/mpegts.c @@ -2169,7 +2169,7 @@ void ff_mpegts_parse_close(MpegTSContext *ts) AVInputFormat ff_mpegts_demuxer = { .name = "mpegts", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 transport stream format"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-TS (MPEG-2 Transport Stream)"), .priv_data_size = sizeof(MpegTSContext), .read_probe = mpegts_probe, .read_header = mpegts_read_header, @@ -2182,7 +2182,7 @@ AVInputFormat ff_mpegts_demuxer = { AVInputFormat ff_mpegtsraw_demuxer = { .name = "mpegtsraw", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 raw transport stream format"), + .long_name = NULL_IF_CONFIG_SMALL("raw MPEG-TS (MPEG-2 Transport Stream)"), .priv_data_size = sizeof(MpegTSContext), .read_header = mpegts_read_header, .read_packet = mpegts_raw_read_packet, diff --git a/libavformat/mpegtsenc.c b/libavformat/mpegtsenc.c index 7456931988..9470c215c3 100644 --- a/libavformat/mpegtsenc.c +++ b/libavformat/mpegtsenc.c @@ -1162,7 +1162,7 @@ static int mpegts_write_end(AVFormatContext *s) AVOutputFormat ff_mpegts_muxer = { .name = "mpegts", - .long_name = NULL_IF_CONFIG_SMALL("MPEG-2 transport stream format"), + .long_name = NULL_IF_CONFIG_SMALL("MPEG-TS (MPEG-2 Transport Stream)"), .mime_type = "video/x-mpegts", .extensions = "ts,m2t", .priv_data_size = sizeof(MpegTSWrite), diff --git a/libavformat/mxfdec.c b/libavformat/mxfdec.c index a68b1a42ec..0a315592cb 100644 --- a/libavformat/mxfdec.c +++ b/libavformat/mxfdec.c @@ -2246,7 +2246,7 @@ static int mxf_read_seek(AVFormatContext *s, int stream_index, int64_t sample_ti AVInputFormat ff_mxf_demuxer = { .name = "mxf", - .long_name = NULL_IF_CONFIG_SMALL("Material eXchange Format"), + .long_name = NULL_IF_CONFIG_SMALL("MXF (Material eXchange Format)"), .priv_data_size = sizeof(MXFContext), .read_probe = mxf_probe, .read_header = mxf_read_header, diff --git a/libavformat/mxfenc.c b/libavformat/mxfenc.c index 597a4f7d72..73847412e7 100644 --- a/libavformat/mxfenc.c +++ b/libavformat/mxfenc.c @@ -1890,7 +1890,7 @@ static int mxf_interleave(AVFormatContext *s, AVPacket *out, AVPacket *pkt, int AVOutputFormat ff_mxf_muxer = { .name = "mxf", - .long_name = NULL_IF_CONFIG_SMALL("Material eXchange Format"), + .long_name = NULL_IF_CONFIG_SMALL("MXF (Material eXchange Format)"), .mime_type = "application/mxf", .extensions = "mxf", .priv_data_size = sizeof(MXFContext), @@ -1905,7 +1905,7 @@ AVOutputFormat ff_mxf_muxer = { AVOutputFormat ff_mxf_d10_muxer = { .name = "mxf_d10", - .long_name = NULL_IF_CONFIG_SMALL("Material eXchange Format, D-10 Mapping"), + .long_name = NULL_IF_CONFIG_SMALL("MXF (Material eXchange Format) D-10 Mapping"), .mime_type = "application/mxf", .priv_data_size = sizeof(MXFContext), .audio_codec = CODEC_ID_PCM_S16LE, diff --git a/libavformat/rawenc.c b/libavformat/rawenc.c index fde5b24e65..f8e5277d6f 100644 --- a/libavformat/rawenc.c +++ b/libavformat/rawenc.c @@ -60,7 +60,7 @@ AVOutputFormat ff_adx_muxer = { #if CONFIG_CAVSVIDEO_MUXER AVOutputFormat ff_cavsvideo_muxer = { .name = "cavsvideo", - .long_name = NULL_IF_CONFIG_SMALL("raw Chinese AVS video"), + .long_name = NULL_IF_CONFIG_SMALL("raw Chinese AVS (Audio Video Standard) video"), .extensions = "cavs", .audio_codec = CODEC_ID_NONE, .video_codec = CODEC_ID_CAVS, diff --git a/libavformat/segment.c b/libavformat/segment.c index 8a0f136c9a..3d55e4cbaa 100644 --- a/libavformat/segment.c +++ b/libavformat/segment.c @@ -264,7 +264,7 @@ static const AVClass seg_class = { AVOutputFormat ff_segment_muxer = { .name = "segment", - .long_name = NULL_IF_CONFIG_SMALL("segment muxer"), + .long_name = NULL_IF_CONFIG_SMALL("segment"), .priv_data_size = sizeof(SegmentContext), .flags = AVFMT_GLOBALHEADER | AVFMT_NOFILE, .write_header = seg_write_header, diff --git a/libavformat/swfdec.c b/libavformat/swfdec.c index 71346de05c..e6036c60bc 100644 --- a/libavformat/swfdec.c +++ b/libavformat/swfdec.c @@ -211,7 +211,7 @@ static int swf_read_packet(AVFormatContext *s, AVPacket *pkt) AVInputFormat ff_swf_demuxer = { .name = "swf", - .long_name = NULL_IF_CONFIG_SMALL("Flash format"), + .long_name = NULL_IF_CONFIG_SMALL("SWF (ShockWave Flash)"), .priv_data_size = sizeof(SWFContext), .read_probe = swf_probe, .read_header = swf_read_header, diff --git a/libavformat/swfenc.c b/libavformat/swfenc.c index fb0fdc5426..f437f5cac2 100644 --- a/libavformat/swfenc.c +++ b/libavformat/swfenc.c @@ -504,7 +504,7 @@ static int swf_write_trailer(AVFormatContext *s) #if CONFIG_SWF_MUXER AVOutputFormat ff_swf_muxer = { .name = "swf", - .long_name = NULL_IF_CONFIG_SMALL("Flash format"), + .long_name = NULL_IF_CONFIG_SMALL("SWF (ShockWave Flash)"), .mime_type = "application/x-shockwave-flash", .extensions = "swf", .priv_data_size = sizeof(SWFContext), @@ -519,7 +519,7 @@ AVOutputFormat ff_swf_muxer = { #if CONFIG_AVM2_MUXER AVOutputFormat ff_avm2_muxer = { .name = "avm2", - .long_name = NULL_IF_CONFIG_SMALL("Flash 9 (AVM2) format"), + .long_name = NULL_IF_CONFIG_SMALL("SWF (ShockWave Flash) (AVM2)"), .mime_type = "application/x-shockwave-flash", .priv_data_size = sizeof(SWFContext), .audio_codec = CODEC_ID_MP3, diff --git a/libavformat/tta.c b/libavformat/tta.c index c5b0792b0e..1726119a6d 100644 --- a/libavformat/tta.c +++ b/libavformat/tta.c @@ -160,7 +160,7 @@ static int tta_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp AVInputFormat ff_tta_demuxer = { .name = "tta", - .long_name = NULL_IF_CONFIG_SMALL("True Audio"), + .long_name = NULL_IF_CONFIG_SMALL("TTA (True Audio)"), .priv_data_size = sizeof(TTAContext), .read_probe = tta_probe, .read_header = tta_read_header, diff --git a/libavformat/wav.c b/libavformat/wav.c index 4ff2c389fc..042bcd8c4a 100644 --- a/libavformat/wav.c +++ b/libavformat/wav.c @@ -207,7 +207,7 @@ static const AVClass wav_muxer_class = { AVOutputFormat ff_wav_muxer = { .name = "wav", - .long_name = NULL_IF_CONFIG_SMALL("WAV format"), + .long_name = NULL_IF_CONFIG_SMALL("WAV / WAVE (Waveform Audio)"), .mime_type = "audio/x-wav", .extensions = "wav", .priv_data_size = sizeof(WAVContext), @@ -588,7 +588,7 @@ static int wav_read_seek(AVFormatContext *s, AVInputFormat ff_wav_demuxer = { .name = "wav", - .long_name = NULL_IF_CONFIG_SMALL("WAV format"), + .long_name = NULL_IF_CONFIG_SMALL("WAV / WAVE (Waveform Audio)"), .priv_data_size = sizeof(WAVContext), .read_probe = wav_probe, .read_header = wav_read_header, -- cgit v1.2.3 From b829b4ce29185625ab8cbcf0ce7a83cf8181ac3b Mon Sep 17 00:00:00 2001 From: "Ronald S. Bultje" Date: Sat, 28 Jul 2012 10:11:00 -0700 Subject: h264: convert loop filter strength dsp function to yasm. This completes the conversion of h264dsp to yasm; note that h264 also uses some dsputil functions, most notably qpel. Performance-wise, the yasm-version is ~10 cycles faster (182->172) on x86-64, and ~8 cycles faster (201->193) on x86-32. --- libavcodec/x86/h264_deblock.asm | 168 ++++++++++++++++++++++++++++++++++++++++ libavcodec/x86/h264dsp_mmx.c | 162 ++------------------------------------ 2 files changed, 175 insertions(+), 155 deletions(-) diff --git a/libavcodec/x86/h264_deblock.asm b/libavcodec/x86/h264_deblock.asm index 0891ef33da..940a8f77e1 100644 --- a/libavcodec/x86/h264_deblock.asm +++ b/libavcodec/x86/h264_deblock.asm @@ -27,6 +27,10 @@ %include "x86inc.asm" %include "x86util.asm" +SECTION_RODATA + +pb_3_1: times 4 db 3, 1 + SECTION .text cextern pb_0 @@ -911,3 +915,167 @@ ff_chroma_intra_body_mmx2: paddb m1, m5 paddb m2, m6 ret + +;----------------------------------------------------------------------------- +; void h264_loop_filter_strength(int16_t bs[2][4][4], uint8_t nnz[40], +; int8_t ref[2][40], int16_t mv[2][40][2], +; int bidir, int edges, int step, +; int mask_mv0, int mask_mv1, int field); +; +; bidir is 0 or 1 +; edges is 1 or 4 +; step is 1 or 2 +; mask_mv0 is 0 or 3 +; mask_mv1 is 0 or 1 +; field is 0 or 1 +;----------------------------------------------------------------------------- +%macro loop_filter_strength_iteration 7 ; edges, step, mask_mv, + ; dir, d_idx, mask_dir, bidir +%define edgesd %1 +%define stepd %2 +%define mask_mvd %3 +%define dir %4 +%define d_idx %5 +%define mask_dir %6 +%define bidir %7 + xor b_idxd, b_idxd ; for (b_idx = 0; b_idx < edges; b_idx += step) +%%.b_idx_loop: +%if mask_dir == 0 + pxor m0, m0 +%endif + test b_idxd, dword mask_mvd + jnz %%.skip_loop_iter ; if (!(b_idx & mask_mv)) +%if bidir == 1 + movd m2, [refq+b_idxq+d_idx+12] ; { ref0[bn] } + punpckldq m2, [refq+b_idxq+d_idx+52] ; { ref0[bn], ref1[bn] } + pshufw m0, [refq+b_idxq+12], 0x44 ; { ref0[b], ref0[b] } + pshufw m1, [refq+b_idxq+52], 0x44 ; { ref1[b], ref1[b] } + pshufw m3, m2, 0x4E ; { ref1[bn], ref0[bn] } + psubb m0, m2 ; { ref0[b] != ref0[bn], + ; ref0[b] != ref1[bn] } + psubb m1, m3 ; { ref1[b] != ref1[bn], + ; ref1[b] != ref0[bn] } + + por m0, m1 + mova m1, [mvq+b_idxq*4+(d_idx+12)*4] + mova m2, [mvq+b_idxq*4+(d_idx+12)*4+mmsize] + mova m3, m1 + mova m4, m2 + psubw m1, [mvq+b_idxq*4+12*4] + psubw m2, [mvq+b_idxq*4+12*4+mmsize] + psubw m3, [mvq+b_idxq*4+52*4] + psubw m4, [mvq+b_idxq*4+52*4+mmsize] + packsswb m1, m2 + packsswb m3, m4 + paddb m1, m6 + paddb m3, m6 + psubusb m1, m5 ; abs(mv[b] - mv[bn]) >= limit + psubusb m3, m5 + packsswb m1, m3 + + por m0, m1 + mova m1, [mvq+b_idxq*4+(d_idx+52)*4] + mova m2, [mvq+b_idxq*4+(d_idx+52)*4+mmsize] + mova m3, m1 + mova m4, m2 + psubw m1, [mvq+b_idxq*4+12*4] + psubw m2, [mvq+b_idxq*4+12*4+mmsize] + psubw m3, [mvq+b_idxq*4+52*4] + psubw m4, [mvq+b_idxq*4+52*4+mmsize] + packsswb m1, m2 + packsswb m3, m4 + paddb m1, m6 + paddb m3, m6 + psubusb m1, m5 ; abs(mv[b] - mv[bn]) >= limit + psubusb m3, m5 + packsswb m1, m3 + + pshufw m1, m1, 0x4E + por m0, m1 + pshufw m1, m0, 0x4E + pminub m0, m1 +%else ; bidir == 0 + movd m0, [refq+b_idxq+12] + psubb m0, [refq+b_idxq+d_idx+12] ; ref[b] != ref[bn] + + mova m1, [mvq+b_idxq*4+12*4] + mova m2, [mvq+b_idxq*4+12*4+mmsize] + psubw m1, [mvq+b_idxq*4+(d_idx+12)*4] + psubw m2, [mvq+b_idxq*4+(d_idx+12)*4+mmsize] + packsswb m1, m2 + paddb m1, m6 + psubusb m1, m5 ; abs(mv[b] - mv[bn]) >= limit + packsswb m1, m1 + por m0, m1 +%endif ; bidir == 1/0 + +%%.skip_loop_iter: + movd m1, [nnzq+b_idxq+12] + por m1, [nnzq+b_idxq+d_idx+12] ; nnz[b] || nnz[bn] + + pminub m1, m7 + pminub m0, m7 + psllw m1, 1 + pxor m2, m2 + pmaxub m1, m0 + punpcklbw m1, m2 + movq [bsq+b_idxq+32*dir], m1 + + add b_idxd, dword stepd + cmp b_idxd, dword edgesd + jl %%.b_idx_loop +%endmacro + +INIT_MMX mmx2 +cglobal h264_loop_filter_strength, 9, 9, 0, bs, nnz, ref, mv, bidir, edges, \ + step, mask_mv0, mask_mv1, field +%define b_idxq bidirq +%define b_idxd bidird + cmp dword fieldm, 0 + mova m7, [pb_1] + mova m5, [pb_3] + je .nofield + mova m5, [pb_3_1] +.nofield: + mova m6, m5 + paddb m5, m5 + + shl dword stepd, 3 + shl dword edgesd, 3 +%if ARCH_X86_32 +%define mask_mv0d mask_mv0m +%define mask_mv1d mask_mv1m +%endif + shl dword mask_mv1d, 3 + shl dword mask_mv0d, 3 + + cmp dword bidird, 0 + jne .bidir + loop_filter_strength_iteration edgesd, stepd, mask_mv1d, 1, -8, 0, 0 + loop_filter_strength_iteration 32, 8, mask_mv0d, 0, -1, -1, 0 + + mova m0, [bsq+mmsize*0] + mova m1, [bsq+mmsize*1] + mova m2, [bsq+mmsize*2] + mova m3, [bsq+mmsize*3] + TRANSPOSE4x4W 0, 1, 2, 3, 4 + mova [bsq+mmsize*0], m0 + mova [bsq+mmsize*1], m1 + mova [bsq+mmsize*2], m2 + mova [bsq+mmsize*3], m3 + RET + +.bidir: + loop_filter_strength_iteration edgesd, stepd, mask_mv1d, 1, -8, 0, 1 + loop_filter_strength_iteration 32, 8, mask_mv0d, 0, -1, -1, 1 + + mova m0, [bsq+mmsize*0] + mova m1, [bsq+mmsize*1] + mova m2, [bsq+mmsize*2] + mova m3, [bsq+mmsize*3] + TRANSPOSE4x4W 0, 1, 2, 3, 4 + mova [bsq+mmsize*0], m0 + mova [bsq+mmsize*1], m1 + mova [bsq+mmsize*2], m2 + mova [bsq+mmsize*3], m3 + RET diff --git a/libavcodec/x86/h264dsp_mmx.c b/libavcodec/x86/h264dsp_mmx.c index 3f18f64f4b..5d9da993a6 100644 --- a/libavcodec/x86/h264dsp_mmx.c +++ b/libavcodec/x86/h264dsp_mmx.c @@ -88,158 +88,10 @@ void ff_h264_luma_dc_dequant_idct_sse2(DCTELEM *output, DCTELEM *input, int qmul /***********************************/ /* deblocking */ -#define h264_loop_filter_strength_iteration_mmx2(bS, nz, ref, mv, bidir, edges, step, mask_mv, dir, d_idx, mask_dir) \ - do { \ - x86_reg b_idx; \ - mask_mv <<= 3; \ - for( b_idx=0; b_idx= limit */ \ - "psubusb %%mm5, %%mm3 \n" \ - "packsswb %%mm3, %%mm1 \n" \ - \ - "por %%mm1, %%mm0 \n" \ - "movq %a7(%1,%2,4), %%mm1 \n" \ - "movq %a8(%1,%2,4), %%mm2 \n" \ - "movq %%mm1, %%mm3 \n" \ - "movq %%mm2, %%mm4 \n" \ - "psubw 48(%1,%2,4), %%mm1 \n" \ - "psubw 56(%1,%2,4), %%mm2 \n" \ - "psubw 208(%1,%2,4), %%mm3 \n" \ - "psubw 216(%1,%2,4), %%mm4 \n" \ - "packsswb %%mm2, %%mm1 \n" \ - "packsswb %%mm4, %%mm3 \n" \ - "paddb %%mm6, %%mm1 \n" \ - "paddb %%mm6, %%mm3 \n" \ - "psubusb %%mm5, %%mm1 \n" /* abs(mv[b] - mv[bn]) >= limit */ \ - "psubusb %%mm5, %%mm3 \n" \ - "packsswb %%mm3, %%mm1 \n" \ - \ - "pshufw $0x4E, %%mm1, %%mm1 \n" \ - "por %%mm1, %%mm0 \n" \ - "pshufw $0x4E, %%mm0, %%mm1 \n" \ - "pminub %%mm1, %%mm0 \n" \ - ::"r"(ref), \ - "r"(mv), \ - "r"(b_idx), \ - "i"(d_idx+12), \ - "i"(d_idx+52), \ - "i"(d_idx*4+48), \ - "i"(d_idx*4+56), \ - "i"(d_idx*4+208), \ - "i"(d_idx*4+216) \ - ); \ - } else { \ - __asm__ volatile( \ - "movd 12(%0,%2), %%mm0 \n" \ - "psubb %a3(%0,%2), %%mm0 \n" /* ref[b] != ref[bn] */ \ - "movq 48(%1,%2,4), %%mm1 \n" \ - "movq 56(%1,%2,4), %%mm2 \n" \ - "psubw %a4(%1,%2,4), %%mm1 \n" \ - "psubw %a5(%1,%2,4), %%mm2 \n" \ - "packsswb %%mm2, %%mm1 \n" \ - "paddb %%mm6, %%mm1 \n" \ - "psubusb %%mm5, %%mm1 \n" /* abs(mv[b] - mv[bn]) >= limit */ \ - "packsswb %%mm1, %%mm1 \n" \ - "por %%mm1, %%mm0 \n" \ - ::"r"(ref), \ - "r"(mv), \ - "r"(b_idx), \ - "i"(d_idx+12), \ - "i"(d_idx*4+48), \ - "i"(d_idx*4+56) \ - ); \ - } \ - } \ - __asm__ volatile( \ - "movd 12(%0,%1), %%mm1 \n" \ - "por %a2(%0,%1), %%mm1 \n" /* nnz[b] || nnz[bn] */ \ - ::"r"(nnz), \ - "r"(b_idx), \ - "i"(d_idx+12) \ - ); \ - __asm__ volatile( \ - "pminub %%mm7, %%mm1 \n" \ - "pminub %%mm7, %%mm0 \n" \ - "psllw $1, %%mm1 \n" \ - "pxor %%mm2, %%mm2 \n" \ - "pmaxub %%mm0, %%mm1 \n" \ - "punpcklbw %%mm2, %%mm1 \n" \ - "movq %%mm1, %a1(%0,%2) \n" \ - ::"r"(bS), \ - "i"(32*dir), \ - "r"(b_idx) \ - :"memory" \ - ); \ - } \ - } while (0) - -static void h264_loop_filter_strength_mmx2( int16_t bS[2][4][4], uint8_t nnz[40], int8_t ref[2][40], int16_t mv[2][40][2], - int bidir, int edges, int step, int mask_mv0, int mask_mv1, int field ) { - __asm__ volatile( - "movq %0, %%mm7 \n" - "movq %1, %%mm6 \n" - ::"m"(ff_pb_1), "m"(ff_pb_3) - ); - if(field) - __asm__ volatile( - "movq %0, %%mm6 \n" - ::"m"(ff_pb_3_1) - ); - __asm__ volatile( - "movq %%mm6, %%mm5 \n" - "paddb %%mm5, %%mm5 \n" - :); - - // could do a special case for dir==0 && edges==1, but it only reduces the - // average filter time by 1.2% - step <<= 3; - edges <<= 3; - h264_loop_filter_strength_iteration_mmx2(bS, nnz, ref, mv, bidir, edges, step, mask_mv1, 1, -8, 0); - h264_loop_filter_strength_iteration_mmx2(bS, nnz, ref, mv, bidir, 32, 8, mask_mv0, 0, -1, -1); - - __asm__ volatile( - "movq (%0), %%mm0 \n\t" - "movq 8(%0), %%mm1 \n\t" - "movq 16(%0), %%mm2 \n\t" - "movq 24(%0), %%mm3 \n\t" - TRANSPOSE4(%%mm0, %%mm1, %%mm2, %%mm3, %%mm4) - "movq %%mm0, (%0) \n\t" - "movq %%mm3, 8(%0) \n\t" - "movq %%mm4, 16(%0) \n\t" - "movq %%mm2, 24(%0) \n\t" - ::"r"(bS[0]) - :"memory" - ); -} +void ff_h264_loop_filter_strength_mmx2(int16_t bS[2][4][4], uint8_t nnz[40], + int8_t ref[2][40], int16_t mv[2][40][2], + int bidir, int edges, int step, + int mask_mv0, int mask_mv1, int field); #define LF_FUNC(DIR, TYPE, DEPTH, OPT) \ void ff_deblock_ ## DIR ## _ ## TYPE ## _ ## DEPTH ## _ ## OPT (uint8_t *pix, int stride, \ @@ -344,12 +196,12 @@ void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, const int chrom { int mm_flags = av_get_cpu_flags(); +#if HAVE_YASM if (chroma_format_idc == 1 && mm_flags & AV_CPU_FLAG_MMX2) { - c->h264_loop_filter_strength= h264_loop_filter_strength_mmx2; + c->h264_loop_filter_strength = ff_h264_loop_filter_strength_mmx2; } if (bit_depth == 8) { -#if HAVE_YASM if (mm_flags & AV_CPU_FLAG_MMX) { c->h264_idct_dc_add = c->h264_idct_add = ff_h264_idct_add_8_mmx; @@ -510,6 +362,6 @@ void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, const int chrom #endif /* HAVE_AVX */ } } -#endif } +#endif } -- cgit v1.2.3 From d1505db06799d625420ff75de40af106c54e8c66 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Tue, 31 Jul 2012 12:17:02 +0200 Subject: x86: yadif: Mark mmxext optimizations as such The yadif mmx optimizations contain the pmaxsw and pmaxub mmxext instructions, causing sigills on CPUs that do not support mmxext. --- libavfilter/x86/yadif.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libavfilter/x86/yadif.c b/libavfilter/x86/yadif.c index 72b06cce0a..beb0824d4f 100644 --- a/libavfilter/x86/yadif.c +++ b/libavfilter/x86/yadif.c @@ -45,9 +45,9 @@ DECLARE_ASM_CONST(16, const xmm_reg, pw_1) = {0x0001000100010001ULL, 0x000100010 #undef COMPILE_TEMPLATE_SSE #endif -#if HAVE_MMX +#if HAVE_MMX2 #undef RENAME -#define RENAME(a) a ## _mmx +#define RENAME(a) a ## _mmx2 #include "yadif_template.c" #endif @@ -58,9 +58,9 @@ av_cold void ff_yadif_init_x86(YADIFContext *yadif) int cpu_flags = av_get_cpu_flags(); #if HAVE_INLINE_ASM -#if HAVE_MMX - if (cpu_flags & AV_CPU_FLAG_MMX) - yadif->filter_line = yadif_filter_line_mmx; +#if HAVE_MMX2 + if (cpu_flags & AV_CPU_FLAG_MMX2) + yadif->filter_line = yadif_filter_line_mmx2; #endif #if HAVE_SSE if (cpu_flags & AV_CPU_FLAG_SSE2) -- cgit v1.2.3 From 8728b381cbacbdff23ba9a85c2fcb78e4fd84966 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Tue, 31 Jul 2012 12:32:29 +0200 Subject: x86: h264dsp: Adjust YASM #ifdefs This fixes compilation with YASM disabled. --- libavcodec/x86/h264dsp_mmx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavcodec/x86/h264dsp_mmx.c b/libavcodec/x86/h264dsp_mmx.c index 5d9da993a6..4bea78807f 100644 --- a/libavcodec/x86/h264dsp_mmx.c +++ b/libavcodec/x86/h264dsp_mmx.c @@ -194,9 +194,9 @@ H264_BIWEIGHT_10_SSE( 4, 10) void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, const int chroma_format_idc) { +#if HAVE_YASM int mm_flags = av_get_cpu_flags(); -#if HAVE_YASM if (chroma_format_idc == 1 && mm_flags & AV_CPU_FLAG_MMX2) { c->h264_loop_filter_strength = ff_h264_loop_filter_strength_mmx2; } @@ -282,9 +282,7 @@ void ff_h264dsp_init_x86(H264DSPContext *c, const int bit_depth, const int chrom } } } -#endif } else if (bit_depth == 10) { -#if HAVE_YASM if (mm_flags & AV_CPU_FLAG_MMX) { if (mm_flags & AV_CPU_FLAG_MMX2) { #if ARCH_X86_32 -- cgit v1.2.3 From 9c9c21eaa1f0adf1c5cd17f9b31a18b979bffe37 Mon Sep 17 00:00:00 2001 From: Samuel Pitoiset Date: Thu, 26 Jul 2012 21:10:09 +0200 Subject: rtmp: do not warn about receiving metadata packets They are managed in get_packet() Signed-off-by: Luca Barbato --- libavformat/rtmpproto.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c index 501e0eddc7..4a35319c4d 100644 --- a/libavformat/rtmpproto.c +++ b/libavformat/rtmpproto.c @@ -1114,7 +1114,8 @@ static int rtmp_parse_result(URLContext *s, RTMPContext *rt, RTMPPacket *pkt) break; case RTMP_PT_VIDEO: case RTMP_PT_AUDIO: - /* Audio and Video packets are parsed in get_packet() */ + case RTMP_PT_METADATA: + /* Audio, Video and Metadata packets are parsed in get_packet() */ break; default: av_log(s, AV_LOG_VERBOSE, "Unknown packet type received 0x%02X\n", pkt->type); -- cgit v1.2.3 From 782e64fbe1daa84c38594db037d0edfac7193c37 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Mon, 30 Jul 2012 07:28:35 +0200 Subject: wv,mpc8: don't return apetag data in packets. --- libavformat/apetag.c | 21 +++++++++++++++------ libavformat/apetag.h | 4 +++- libavformat/mpc8.c | 9 ++++++++- libavformat/wv.c | 9 ++++++++- 4 files changed, 34 insertions(+), 9 deletions(-) diff --git a/libavformat/apetag.c b/libavformat/apetag.c index 062f74632c..dd746313b5 100644 --- a/libavformat/apetag.c +++ b/libavformat/apetag.c @@ -113,40 +113,47 @@ static int ape_tag_read_field(AVFormatContext *s) return 0; } -void ff_ape_parse_tag(AVFormatContext *s) +int64_t ff_ape_parse_tag(AVFormatContext *s) { AVIOContext *pb = s->pb; int file_size = avio_size(pb); uint32_t val, fields, tag_bytes; uint8_t buf[8]; + int64_t tag_start; int i; if (file_size < APE_TAG_FOOTER_BYTES) - return; + return 0; avio_seek(pb, file_size - APE_TAG_FOOTER_BYTES, SEEK_SET); avio_read(pb, buf, 8); /* APETAGEX */ if (strncmp(buf, "APETAGEX", 8)) { - return; + return 0; } val = avio_rl32(pb); /* APE tag version */ if (val > APE_TAG_VERSION) { av_log(s, AV_LOG_ERROR, "Unsupported tag version. (>=%d)\n", APE_TAG_VERSION); - return; + return 0; } tag_bytes = avio_rl32(pb); /* tag size */ if (tag_bytes - APE_TAG_FOOTER_BYTES > (1024 * 1024 * 16)) { av_log(s, AV_LOG_ERROR, "Tag size is way too big\n"); - return; + return 0; + } + + tag_start = file_size - tag_bytes - APE_TAG_FOOTER_BYTES; + if (tag_start < 0) { + av_log(s, AV_LOG_ERROR, "Invalid tag size %u.\n", tag_bytes); + return 0; } fields = avio_rl32(pb); /* number of fields */ if (fields > 65536) { av_log(s, AV_LOG_ERROR, "Too many tag fields (%d)\n", fields); - return; + return 0; } val = avio_rl32(pb); /* flags */ @@ -159,4 +166,6 @@ void ff_ape_parse_tag(AVFormatContext *s) for (i=0; iseekable) { int64_t pos = avio_tell(s->pb); - ff_ape_parse_tag(s); + c->apetag_start = ff_ape_parse_tag(s); avio_seek(s->pb, pos, SEEK_SET); } @@ -258,6 +260,11 @@ static int mpc8_read_packet(AVFormatContext *s, AVPacket *pkt) while(!s->pb->eof_reached){ pos = avio_tell(s->pb); + + /* don't return bogus packets with the ape tag data */ + if (c->apetag_start && pos >= c->apetag_start) + return AVERROR_EOF; + mpc8_get_chunk_header(s->pb, &tag, &size); if (size < 0) return -1; diff --git a/libavformat/wv.c b/libavformat/wv.c index 3fd1abcb87..39bb6144d3 100644 --- a/libavformat/wv.c +++ b/libavformat/wv.c @@ -64,6 +64,8 @@ typedef struct { int block_parsed; uint8_t extra[WV_EXTRA_SIZE]; int64_t pos; + + int64_t apetag_start; } WVContext; static int wv_probe(AVProbeData *p) @@ -88,6 +90,11 @@ static int wv_read_block_header(AVFormatContext *ctx, AVIOContext *pb, uint32_t chmask; wc->pos = avio_tell(pb); + + /* don't return bogus packets with the ape tag data */ + if (wc->apetag_start && wc->pos >= wc->apetag_start) + return AVERROR_EOF; + if (!append) { tag = avio_rl32(pb); if (tag != MKTAG('w', 'v', 'p', 'k')) @@ -252,7 +259,7 @@ static int wv_read_header(AVFormatContext *s) if (s->pb->seekable) { int64_t cur = avio_tell(s->pb); - ff_ape_parse_tag(s); + wc->apetag_start = ff_ape_parse_tag(s); if (!av_dict_get(s->metadata, "", NULL, AV_DICT_IGNORE_SUFFIX)) ff_id3v1_read(s); avio_seek(s->pb, cur, SEEK_SET); -- cgit v1.2.3 From 263dbe9d953bfa717cd46698511cdcdc3d5d74b1 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Sun, 29 Jul 2012 22:19:35 +0200 Subject: mpc: return more meaningful error codes. --- libavformat/mpc.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/libavformat/mpc.c b/libavformat/mpc.c index 03d362998f..404950b836 100644 --- a/libavformat/mpc.c +++ b/libavformat/mpc.c @@ -59,17 +59,17 @@ static int mpc_read_header(AVFormatContext *s) if(avio_rl24(s->pb) != MKTAG('M', 'P', '+', 0)){ av_log(s, AV_LOG_ERROR, "Not a Musepack file\n"); - return -1; + return AVERROR_INVALIDDATA; } c->ver = avio_r8(s->pb); if(c->ver != 0x07 && c->ver != 0x17){ av_log(s, AV_LOG_ERROR, "Can demux Musepack SV7, got version %02X\n", c->ver); - return -1; + return AVERROR_INVALIDDATA; } c->fcount = avio_rl32(s->pb); if((int64_t)c->fcount * sizeof(MPCFrame) >= UINT_MAX){ av_log(s, AV_LOG_ERROR, "Too many frames, seeking is not possible\n"); - return -1; + return AVERROR_INVALIDDATA; } if(c->fcount){ c->frames = av_malloc(c->fcount * sizeof(MPCFrame)); @@ -122,7 +122,7 @@ static int mpc_read_packet(AVFormatContext *s, AVPacket *pkt) int64_t pos; if (c->curframe >= c->fcount && c->fcount) - return -1; + return AVERROR_EOF; if(c->curframe != c->lastframe + 1){ avio_seek(s->pb, c->frames[c->curframe].pos, SEEK_SET); @@ -151,8 +151,8 @@ static int mpc_read_packet(AVFormatContext *s, AVPacket *pkt) } c->curbits = (curbits + size2) & 0x1F; - if (av_new_packet(pkt, size) < 0) - return AVERROR(EIO); + if ((ret = av_new_packet(pkt, size)) < 0) + return ret; pkt->data[0] = curbits; pkt->data[1] = (c->curframe > c->fcount) && c->fcount; @@ -166,7 +166,7 @@ static int mpc_read_packet(AVFormatContext *s, AVPacket *pkt) avio_seek(s->pb, -4, SEEK_CUR); if(ret < size){ av_free_packet(pkt); - return AVERROR(EIO); + return ret < 0 ? ret : AVERROR(EIO); } pkt->size = ret + 4; @@ -214,7 +214,7 @@ static int mpc_read_seek(AVFormatContext *s, int stream_index, int64_t timestamp ret = av_read_frame(s, pkt); if (ret < 0){ c->curframe = lastframe; - return -1; + return ret; } av_free_packet(pkt); } -- cgit v1.2.3 From f2ed006c90ccb65cd143d8b0fcfc28ffb98c4289 Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Mon, 30 Jul 2012 07:29:34 +0200 Subject: mpc8: return more meaningful error codes. --- libavformat/mpc8.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libavformat/mpc8.c b/libavformat/mpc8.c index 6b9f77e6ab..b6837c52f7 100644 --- a/libavformat/mpc8.c +++ b/libavformat/mpc8.c @@ -202,7 +202,7 @@ static int mpc8_read_header(AVFormatContext *s) c->header_pos = avio_tell(pb); if(avio_rl32(pb) != TAG_MPCK){ av_log(s, AV_LOG_ERROR, "Not a Musepack8 file\n"); - return -1; + return AVERROR_INVALIDDATA; } while(!pb->eof_reached){ @@ -214,14 +214,14 @@ static int mpc8_read_header(AVFormatContext *s) } if(tag != TAG_STREAMHDR){ av_log(s, AV_LOG_ERROR, "Stream header not found\n"); - return -1; + return AVERROR_INVALIDDATA; } pos = avio_tell(pb); avio_skip(pb, 4); //CRC c->ver = avio_r8(pb); if(c->ver != 8){ av_log(s, AV_LOG_ERROR, "Unknown stream version %d\n", c->ver); - return -1; + return AVERROR_PATCHWELCOME; } c->samples = ffio_read_varlen(pb); ffio_read_varlen(pb); //silence samples at the beginning -- cgit v1.2.3