mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-06 15:49:50 +08:00
lavc: use designated initialisers for all codecs.
It's more readable and less prone to breakage.
This commit is contained in:
@ -1724,28 +1724,26 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
|
||||
}
|
||||
|
||||
AVCodec ff_ffv1_decoder = {
|
||||
"ffv1",
|
||||
AVMEDIA_TYPE_VIDEO,
|
||||
CODEC_ID_FFV1,
|
||||
sizeof(FFV1Context),
|
||||
decode_init,
|
||||
NULL,
|
||||
common_end,
|
||||
decode_frame,
|
||||
CODEC_CAP_DR1 /*| CODEC_CAP_DRAW_HORIZ_BAND*/ | CODEC_CAP_SLICE_THREADS,
|
||||
NULL,
|
||||
.name = "ffv1",
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.id = CODEC_ID_FFV1,
|
||||
.priv_data_size = sizeof(FFV1Context),
|
||||
.init = decode_init,
|
||||
.close = common_end,
|
||||
.decode = decode_frame,
|
||||
.capabilities = CODEC_CAP_DR1 /*| CODEC_CAP_DRAW_HORIZ_BAND*/ | CODEC_CAP_SLICE_THREADS,
|
||||
.long_name= NULL_IF_CONFIG_SMALL("FFmpeg video codec #1"),
|
||||
};
|
||||
|
||||
#if CONFIG_FFV1_ENCODER
|
||||
AVCodec ff_ffv1_encoder = {
|
||||
"ffv1",
|
||||
AVMEDIA_TYPE_VIDEO,
|
||||
CODEC_ID_FFV1,
|
||||
sizeof(FFV1Context),
|
||||
encode_init,
|
||||
encode_frame,
|
||||
common_end,
|
||||
.name = "ffv1",
|
||||
.type = AVMEDIA_TYPE_VIDEO,
|
||||
.id = CODEC_ID_FFV1,
|
||||
.priv_data_size = sizeof(FFV1Context),
|
||||
.init = encode_init,
|
||||
.encode = encode_frame,
|
||||
.close = common_end,
|
||||
.capabilities = CODEC_CAP_SLICE_THREADS,
|
||||
.pix_fmts= (const enum PixelFormat[]){PIX_FMT_YUV420P, PIX_FMT_YUV444P, PIX_FMT_YUV422P, PIX_FMT_YUV411P, PIX_FMT_YUV410P, PIX_FMT_RGB32, PIX_FMT_YUV420P16, PIX_FMT_YUV422P16, PIX_FMT_YUV444P16, PIX_FMT_NONE},
|
||||
.long_name= NULL_IF_CONFIG_SMALL("FFmpeg video codec #1"),
|
||||
|
Reference in New Issue
Block a user