diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-07-17 12:54:31 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2011-07-29 08:42:34 +0200 |
commit | ec6402b7c595c3ceed6d1b8c1b75c6aa8336e052 (patch) | |
tree | b0ac16ae01c2bb355766ae164a1b44fc88617750 /libavcodec/pngenc.c | |
parent | 3ad168412600e16dfaa4b41b21322a82a8535990 (diff) | |
download | ffmpeg-ec6402b7c595c3ceed6d1b8c1b75c6aa8336e052.tar.gz |
lavc: use designated initialisers for all codecs.
It's more readable and less prone to breakage.
Diffstat (limited to 'libavcodec/pngenc.c')
-rw-r--r-- | libavcodec/pngenc.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/libavcodec/pngenc.c b/libavcodec/pngenc.c index c2ac4901d7..9325348443 100644 --- a/libavcodec/pngenc.c +++ b/libavcodec/pngenc.c @@ -437,13 +437,12 @@ static av_cold int png_enc_init(AVCodecContext *avctx){ } AVCodec ff_png_encoder = { - "png", - AVMEDIA_TYPE_VIDEO, - CODEC_ID_PNG, - sizeof(PNGEncContext), - png_enc_init, - encode_frame, - NULL, //encode_end, + .name = "png", + .type = AVMEDIA_TYPE_VIDEO, + .id = CODEC_ID_PNG, + .priv_data_size = sizeof(PNGEncContext), + .init = png_enc_init, + .encode = encode_frame, .pix_fmts= (const enum PixelFormat[]){PIX_FMT_RGB24, PIX_FMT_RGB32, PIX_FMT_PAL8, PIX_FMT_GRAY8, PIX_FMT_MONOBLACK, PIX_FMT_NONE}, .long_name= NULL_IF_CONFIG_SMALL("PNG image"), }; |