summaryrefslogtreecommitdiff
path: root/sys/msdk/gstmsdkenc.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/msdk/gstmsdkenc.c')
-rw-r--r--sys/msdk/gstmsdkenc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/msdk/gstmsdkenc.c b/sys/msdk/gstmsdkenc.c
index 50edcc3c3..79b47fc5a 100644
--- a/sys/msdk/gstmsdkenc.c
+++ b/sys/msdk/gstmsdkenc.c
@@ -265,6 +265,9 @@ gst_msdkenc_init_encoder (GstMsdkEnc * thiz)
msdk_status_to_string (status));
}
+ if (thiz->use_video_memory)
+ request[0].NumFrameSuggested +=
+ gst_msdk_context_get_shared_async_depth (thiz->context);
thiz->num_vpp_surfaces = request[0].NumFrameSuggested;
if (thiz->use_video_memory)
@@ -1157,6 +1160,8 @@ gst_msdkenc_start (GstVideoEncoder * encoder)
thiz->context);
}
+ gst_msdk_context_add_shared_async_depth (thiz->context, thiz->async_depth);
+
/* Set the minimum pts to some huge value (1000 hours). This keeps
the dts at the start of the stream from needing to be
negative. */