1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-13 21:28:01 +02:00

act, bintext, wtvenc: use named struct initializers

This commit is contained in:
Aurelien Jacobs 2011-09-26 00:19:56 +02:00
parent f85c9b7771
commit c894449fc4
3 changed files with 42 additions and 44 deletions

View File

@ -198,10 +198,10 @@ static int read_packet(AVFormatContext *s,
} }
AVInputFormat ff_act_demuxer = { AVInputFormat ff_act_demuxer = {
"act", .name = "act",
"ACT Voice file format", .long_name = "ACT Voice file format",
sizeof(ACTContext), .priv_data_size = sizeof(ACTContext),
probe, .read_probe = probe,
read_header, .read_header = read_header,
read_packet .read_packet = read_packet,
}; };

View File

@ -330,47 +330,45 @@ static int read_packet(AVFormatContext *s,
#if CONFIG_BINTEXT_DEMUXER #if CONFIG_BINTEXT_DEMUXER
AVInputFormat ff_bintext_demuxer = { AVInputFormat ff_bintext_demuxer = {
"bin", .name = "bin",
NULL_IF_CONFIG_SMALL("Binary text"), .long_name = NULL_IF_CONFIG_SMALL("Binary text"),
sizeof(BinDemuxContext), .priv_data_size = sizeof(BinDemuxContext),
NULL, .read_header = bintext_read_header,
bintext_read_header, .read_packet = read_packet,
read_packet, .extensions = "bin",
.extensions = "bin",
}; };
#endif #endif
#if CONFIG_XBIN_DEMUXER #if CONFIG_XBIN_DEMUXER
AVInputFormat ff_xbin_demuxer = { AVInputFormat ff_xbin_demuxer = {
"xbin", .name = "xbin",
NULL_IF_CONFIG_SMALL("eXtended BINary text (XBIN)"), .long_name = NULL_IF_CONFIG_SMALL("eXtended BINary text (XBIN)"),
sizeof(BinDemuxContext), .priv_data_size = sizeof(BinDemuxContext),
xbin_probe, .read_probe = xbin_probe,
xbin_read_header, .read_header = xbin_read_header,
read_packet, .read_packet = read_packet,
}; };
#endif #endif
#if CONFIG_ADF_DEMUXER #if CONFIG_ADF_DEMUXER
AVInputFormat ff_adf_demuxer = { AVInputFormat ff_adf_demuxer = {
"adf", .name = "adf",
NULL_IF_CONFIG_SMALL("Artworx Data Format"), .long_name = NULL_IF_CONFIG_SMALL("Artworx Data Format"),
sizeof(BinDemuxContext), .priv_data_size = sizeof(BinDemuxContext),
NULL, .read_header = adf_read_header,
adf_read_header, .read_packet = read_packet,
read_packet, .extensions = "adf",
.extensions = "adf",
}; };
#endif #endif
#if CONFIG_IDF_DEMUXER #if CONFIG_IDF_DEMUXER
AVInputFormat ff_idf_demuxer = { AVInputFormat ff_idf_demuxer = {
"idf", .name = "idf",
NULL_IF_CONFIG_SMALL("iCE Draw File"), .long_name = NULL_IF_CONFIG_SMALL("iCE Draw File"),
sizeof(BinDemuxContext), .priv_data_size = sizeof(BinDemuxContext),
idf_probe, .read_probe = idf_probe,
idf_read_header, .read_header = idf_read_header,
read_packet, .read_packet = read_packet,
.extensions = "idf", .extensions = "idf",
}; };
#endif #endif

View File

@ -708,15 +708,15 @@ static int write_trailer(AVFormatContext *s)
} }
AVOutputFormat ff_wtv_muxer = { AVOutputFormat ff_wtv_muxer = {
"wtv", .name = "wtv",
NULL_IF_CONFIG_SMALL("Windows Television (WTV)"), .long_name = NULL_IF_CONFIG_SMALL("Windows Television (WTV)"),
NULL, .extensions = "wtv",
"wtv", .priv_data_size = sizeof(WtvContext),
sizeof(WtvContext), .audio_codec = CODEC_ID_MP2,
CODEC_ID_MP2, .video_codec = CODEC_ID_MPEG2VIDEO,
CODEC_ID_MPEG2VIDEO, .write_header = write_header,
write_header, .write_packet = write_packet,
write_packet, .write_trailer = write_trailer,
write_trailer, .codec_tag = (const AVCodecTag* const []){ ff_codec_bmp_tags,
.codec_tag= (const AVCodecTag* const []){ff_codec_bmp_tags, ff_codec_wav_tags, 0}, ff_codec_wav_tags, 0 },
}; };