summaryrefslogtreecommitdiff
path: root/libavformat/pcmdec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2011-09-24 22:37:24 +0200
committerMichael Niedermayer <michaelni@gmx.at>2011-09-24 22:39:52 +0200
commiteae3cf06a5410cf6d06235de4ceea28e33e53be3 (patch)
tree126512350cc96249cd1d157969a87a0018f6ab53 /libavformat/pcmdec.c
parent0f2297a9b958b8598b17f139e7ec2d7e593a0a7c (diff)
parent2b4e49d4281690db67073ba644ad2ffc17767cdf (diff)
Merge remote-tracking branch 'qatar/master'
* qatar/master: flvdec: Fix invalid pointer deferences when parsing index configure: disable hardware capabilities ELF section with suncc on Solaris x86 Use explicit struct initializers for AVCodec declarations. Use explicit struct initializers for AVOutputFormat/AVInputFormat declarations. adpcmenc: Set bits_per_coded_sample adpcmenc: fix QT IMA ADPCM encoder adpcmdec: Fix QT IMA ADPCM decoder permit decoding of multichannel ADPCM_EA_XAS Fix input buffer size check in adpcm_ea decoder. fft: avoid a signed overflow mpegps: Handle buffer exhaustion when reading packets. Conflicts: libavcodec/adpcm.c libavcodec/adpcmenc.c libavdevice/alsa-audio-enc.c libavformat/flvdec.c libavformat/mpeg.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/pcmdec.c')
-rw-r--r--libavformat/pcmdec.c38
1 files changed, 18 insertions, 20 deletions
diff --git a/libavformat/pcmdec.c b/libavformat/pcmdec.c
index 676e3a19d1..3e6132b880 100644
--- a/libavformat/pcmdec.c
+++ b/libavformat/pcmdec.c
@@ -54,26 +54,24 @@ static const AVOption pcm_options[] = {
{ NULL },
};
-#define PCMDEF(name, long_name, ext, codec) \
-static const AVClass name ## _demuxer_class = {\
- .class_name = #name " demuxer",\
- .item_name = av_default_item_name,\
- .option = pcm_options,\
- .version = LIBAVUTIL_VERSION_INT,\
-};\
-AVInputFormat ff_pcm_ ## name ## _demuxer = {\
- #name,\
- NULL_IF_CONFIG_SMALL(long_name),\
- sizeof(RawAudioDemuxerContext),\
- NULL,\
- ff_raw_read_header,\
- raw_read_packet,\
- NULL,\
- pcm_read_seek,\
- .flags= AVFMT_GENERIC_INDEX,\
- .extensions = ext,\
- .value = codec,\
- .priv_class = &name ## _demuxer_class,\
+#define PCMDEF(name_, long_name_, ext, codec) \
+static const AVClass name_ ## _demuxer_class = { \
+ .class_name = #name_ " demuxer", \
+ .item_name = av_default_item_name, \
+ .option = pcm_options, \
+ .version = LIBAVUTIL_VERSION_INT, \
+}; \
+AVInputFormat ff_pcm_ ## name_ ## _demuxer = { \
+ .name = #name_, \
+ .long_name = NULL_IF_CONFIG_SMALL(long_name_), \
+ .priv_data_size = sizeof(RawAudioDemuxerContext), \
+ .read_header = ff_raw_read_header, \
+ .read_packet = raw_read_packet, \
+ .read_seek = pcm_read_seek, \
+ .flags = AVFMT_GENERIC_INDEX, \
+ .extensions = ext, \
+ .value = codec, \
+ .priv_class = &name_ ## _demuxer_class, \
};
PCMDEF(f64be, "PCM 64 bit floating-point big-endian format",