Commit dc4b64c9 authored by Timo Rothenpieler's avatar Timo Rothenpieler Committed by Jean-Baptiste Kempf

Make vaapi decoder compatible with latest libva changes

Signed-off-by: default avatarJean-Baptiste Kempf <jb@videolan.org>
parent 10ee7ff4
...@@ -41,6 +41,11 @@ ...@@ -41,6 +41,11 @@
#include "va.h" #include "va.h"
#include "copy.h" #include "copy.h"
#ifndef VA_SURFACE_ATTRIB_SETTABLE
#define vaCreateSurfaces(d, f, w, h, s, ns, a, na) \
vaCreateSurfaces(d, w, h, f, ns, s)
#endif
static int Create( vlc_va_t *, int, const es_format_t * ); static int Create( vlc_va_t *, int, const es_format_t * );
static void Delete( vlc_va_t * ); static void Delete( vlc_va_t * );
...@@ -258,8 +263,8 @@ static int CreateSurfaces( vlc_va_sys_t *p_va, void **pp_hw_ctx, vlc_fourcc_t *p ...@@ -258,8 +263,8 @@ static int CreateSurfaces( vlc_va_sys_t *p_va, void **pp_hw_ctx, vlc_fourcc_t *p
/* Create surfaces */ /* Create surfaces */
VASurfaceID pi_surface_id[p_va->i_surface_count]; VASurfaceID pi_surface_id[p_va->i_surface_count];
if( vaCreateSurfaces( p_va->p_display, i_width, i_height, VA_RT_FORMAT_YUV420, if( vaCreateSurfaces( p_va->p_display, VA_RT_FORMAT_YUV420, i_width, i_height,
p_va->i_surface_count, pi_surface_id ) ) pi_surface_id, p_va->i_surface_count, NULL, 0 ) )
{ {
for( int i = 0; i < p_va->i_surface_count; i++ ) for( int i = 0; i < p_va->i_surface_count; i++ )
p_va->p_surface[i].i_id = VA_INVALID_SURFACE; p_va->p_surface[i].i_id = VA_INVALID_SURFACE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment