Unified · Split
| @@ -32,8 +32,8 @@ · 31 unmodified lines | |||
| 32 | static av_cold int raw_init_encoder(AVCodecContext *avctx) | 32 | static av_cold int raw_init_encoder(AVCodecContext *avctx) |
| 33 | { | 33 | { |
| 34 | avctx->coded_frame = (AVFrame *)avctx->priv_data; | 34 | avctx->coded_frame = (AVFrame *)avctx->priv_data; |
| 35 | avcodec_get_frame_defaults(avctx->coded_frame); | ||
| 35 | avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I; | 36 | avctx->coded_frame->pict_type = AV_PICTURE_TYPE_I; |
| 36 | avctx->coded_frame->key_frame = 1; | ||
| 37 | avctx->bits_per_coded_sample = av_get_bits_per_pixel(&av_pix_fmt_descriptors[avctx->pix_fmt]); | 37 | avctx->bits_per_coded_sample = av_get_bits_per_pixel(&av_pix_fmt_descriptors[avctx->pix_fmt]); |
| 38 | if(!avctx->codec_tag) | 38 | if(!avctx->codec_tag) |
| 39 | avctx->codec_tag = avcodec_pix_fmt_to_codec_tag(avctx->pix_fmt); | 39 | avctx->codec_tag = avcodec_pix_fmt_to_codec_tag(avctx->pix_fmt); |