hardware/intel/intel-driver
Revision | 6dc5b8bc2ba06e2dc48ee1277c250ca579058d21 (tree) |
---|---|
Zeit | 2014-12-14 01:42:17 |
Autor | Xiang, Haihao <haihao.xiang@inte...> |
Commiter | Xiang, Haihao |
HEVC: Add the frame store array
The function to update the frame store index will be added later
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
(cherry picked from commit e758dcb38b37773df7253bc2ea7910adaf31258d)
@@ -253,6 +253,7 @@ gen9_hcpd_context_init(VADriverContextP ctx, struct object_config *object_config | ||
253 | 253 | { |
254 | 254 | struct intel_driver_data *intel = intel_driver_data(ctx); |
255 | 255 | struct gen9_hcpd_context *gen9_hcpd_context = calloc(1, sizeof(struct gen9_hcpd_context)); |
256 | + int i; | |
256 | 257 | |
257 | 258 | if (!gen9_hcpd_context) |
258 | 259 | return NULL; |
@@ -261,6 +262,12 @@ gen9_hcpd_context_init(VADriverContextP ctx, struct object_config *object_config | ||
261 | 262 | gen9_hcpd_context->base.run = gen9_hcpd_decode_picture; |
262 | 263 | gen9_hcpd_context->base.batch = intel_batchbuffer_new(intel, I915_EXEC_VEBOX, 0); |
263 | 264 | |
265 | + for (i = 0; i < ARRAY_ELEMS(gen9_hcpd_context->reference_surfaces); i++) { | |
266 | + gen9_hcpd_context->reference_surfaces[i].surface_id = VA_INVALID_ID; | |
267 | + gen9_hcpd_context->reference_surfaces[i].frame_store_id = -1; | |
268 | + gen9_hcpd_context->reference_surfaces[i].obj_surface = NULL; | |
269 | + } | |
270 | + | |
264 | 271 | return (struct hw_context *)gen9_hcpd_context; |
265 | 272 | } |
266 | 273 |
@@ -41,6 +41,8 @@ struct gen9_hcpd_context | ||
41 | 41 | { |
42 | 42 | struct hw_context base; |
43 | 43 | |
44 | + GenFrameStore reference_surfaces[MAX_GEN_HCP_REFERENCE_FRAMES]; | |
45 | + | |
44 | 46 | uint16_t picture_width_in_pixels; |
45 | 47 | uint16_t picture_height_in_pixels; |
46 | 48 | uint16_t picture_width_in_ctbs; |