Add a larger warning more clearly explaining the consequences of missing packed header support in the driver. Also only write the extradata if the user actually requests it via the GLOBAL_HEADER flag.
Showing the changes to libavcodec/vaapi_encode_mpeg2.c (1 of 8 files). Show all
Unified · Split
| @@ -615,8 +615,8 @@ static av_cold int vaapi_encode_mpeg2_init(AVCodecContext *avctx) · 614 unmodified lines | ||
| 615 | 615 | return AVERROR(EINVAL); |
| 616 | 616 | } |
| 617 | 617 | |
| 618 | − ctx->va_packed_headers = VA_ENC_PACKED_HEADER_SEQUENCE | | |
| 619 | − VA_ENC_PACKED_HEADER_PICTURE; | |
| 618 | + ctx->desired_packed_headers = VA_ENC_PACKED_HEADER_SEQUENCE | | |
| 619 | + VA_ENC_PACKED_HEADER_PICTURE; | |
| 620 | 620 | |
| 621 | 621 | ctx->surface_width = FFALIGN(avctx->width, 16); |
| 622 | 622 | ctx->surface_height = FFALIGN(avctx->height, 16); |