OSDN Git Service

HEVC10bit ENC: work around gpu hang when p010->nv12
authorPengfei Qu <Pengfei.Qu@intel.com>
Thu, 8 Sep 2016 00:43:27 +0000 (08:43 +0800)
committerXiang, Haihao <haihao.xiang@intel.com>
Thu, 8 Sep 2016 07:48:41 +0000 (15:48 +0800)
Signed-off-by: Pengfei Qu <Pengfei.Qu@intel.com>
Reviewed-by: Zhao Yakui <yakui.zhao@intel.com>
src/gen9_vme.c
src/i965_drv_video.h

index 8cbe052..4a7d932 100644 (file)
@@ -1839,6 +1839,7 @@ static VAStatus gen9_intel_init_hevc_surface(VADriverContextP ctx,
             &rect);
         assert(status == VA_STATUS_SUCCESS);
         hevc_encoder_surface->has_p010_to_nv12_done = 1;
+        i965_SyncSurface(ctx,hevc_encoder_surface->nv12_surface_id);
     }
     return VA_STATUS_SUCCESS;
 }
index d9644a7..77e32d8 100644 (file)
@@ -553,6 +553,8 @@ extern VAStatus i965_CreateSurfaces(VADriverContextP ctx,
                     int format,
                     int num_surfaces,
                     VASurfaceID *surfaces);
+extern VAStatus i965_SyncSurface(VADriverContextP ctx,
+                    VASurfaceID render_target);
 
 #define I965_SURFACE_MEM_NATIVE             0
 #define I965_SURFACE_MEM_GEM_FLINK          1