[FFmpeg-devel,v3,09/12] vaapi_encode_mpeg2: Add missing marker bit in time_code

Submitted by Mark Thompson on Feb. 10, 2019, 7:47 p.m.

Details

Message ID 20190210194705.3598-9-sw@jkqxz.net
State New
Headers show

Commit Message

Mark Thompson Feb. 10, 2019, 7:47 p.m.
We don't have anything useful to put in this field, but there is still
meant to be a marker bit in the middle of it.
---
 libavcodec/vaapi_encode_mpeg2.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/libavcodec/vaapi_encode_mpeg2.c b/libavcodec/vaapi_encode_mpeg2.c
index 174611ff24..26d2433e1c 100644
--- a/libavcodec/vaapi_encode_mpeg2.c
+++ b/libavcodec/vaapi_encode_mpeg2.c
@@ -313,7 +313,8 @@  static int vaapi_encode_mpeg2_init_sequence_params(AVCodecContext *avctx)
 
     goph->group_start_code = MPEG2_START_GROUP;
 
-    goph->time_code   = 0;
+    // Marker bit in the middle of time_code.
+    goph->time_code   = 1 << 12;
     goph->closed_gop  = 1;
     goph->broken_link = 0;