[Libva] [LIBVA_INTEL_DRIVER][PATCH V2 4/8] Initialize internal context based on Render ring earlier
Zhao Yakui
yakui.zhao at intel.com
Fri Nov 11 01:56:06 UTC 2016
V1->V2: Remove the unnecessary implicit initialization in gen75_vpp_fmt_cvt
as it is already initalized.
Signed-off-by: Zhao Yakui <yakui.zhao at intel.com>
---
src/gen75_picture_process.c | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/src/gen75_picture_process.c b/src/gen75_picture_process.c
index 0b681f1..6e1102a 100644
--- a/src/gen75_picture_process.c
+++ b/src/gen75_picture_process.c
@@ -53,11 +53,6 @@ gen75_vpp_fmt_cvt(VADriverContextP ctx,
struct intel_video_process_context *proc_ctx =
(struct intel_video_process_context *)hw_context;
- /* implicity surface format coversion and scaling */
- if(proc_ctx->vpp_fmt_cvt_ctx == NULL){
- proc_ctx->vpp_fmt_cvt_ctx = i965_proc_context_init(ctx, NULL);
- }
-
va_status = i965_proc_picture(ctx, profile, codec_state,
proc_ctx->vpp_fmt_cvt_ctx);
@@ -148,6 +143,12 @@ gen75_proc_picture(VADriverContextP ctx,
goto error;
}
+ if (pipeline_param->num_filters == 0 || pipeline_param->filters == NULL ){
+ /* explicitly initialize the VPP based on Render ring */
+ if (proc_ctx->vpp_fmt_cvt_ctx == NULL)
+ proc_ctx->vpp_fmt_cvt_ctx = i965_proc_context_init(ctx, NULL);
+ }
+
if (!obj_dst_surf->bo) {
unsigned int is_tiled = 1;
unsigned int fourcc = VA_FOURCC_NV12;
--
1.9.0
More information about the Libva
mailing list