From: Zhao Yakui <[email protected]>
Signed-off-by: Zhao Yakui <[email protected]>
---
src/i965_drv_video.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/src/i965_drv_video.c b/src/i965_drv_video.c
index eefff39..5a61bde 100644
--- a/src/i965_drv_video.c
+++ b/src/i965_drv_video.c
@@ -2388,6 +2388,16 @@ i965_BeginPicture(VADriverContextP ctx,
obj_context->codec_state.encode.num_packed_header_params_ext = 0;
obj_context->codec_state.encode.num_packed_header_data_ext = 0;
obj_context->codec_state.encode.slice_index = 0;
+
+ /*
+ * Based on ROI definition in va/va.h, the ROI set through this
+ * structure is applicable only to the current frame or field.
+ * That is to say: it is on-the-fly setting. If it is not set,
+ * the current frame doesn't use ROI.
+ * It is uncertain whether the other misc buffer should be released.
+ * So only release the previous ROI buffer.
+ */
+
i965_release_buffer_store(&obj_context->codec_state.encode.misc_param[VAEncMiscParameterTypeROI]);
} else {
obj_context->codec_state.decode.current_render_target = render_target;
i965_release_buffer_store(&obj_context->codec_state.decode.pic_param);
--
1.7.10.1
_______________________________________________
Libva mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libva