• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

hardware/intel/libva


Commit MetaInfo

修订版a7dbd4e05ab1f30d7f020ff0b25d8f1948924f91 (tree)
时间2009-08-28 18:33:21
作者Austin Yuan <shengquan.yuan@inte...>
CommiterAustin Yuan

Log Message

Merge branch 'master-fd.o'

Conflicts:
Makefile.am
configure.ac
dummy_drv_video/dummy_drv_video.c
i965_drv_video/Makefile.am
i965_drv_video/i965_drv_video.c
src/Makefile.am
src/va.c
src/va.h
src/va_backend.h
src/x11/va_x11.c
test/test_12.c

Signed-off-by: Austin Yuan <shengquan.yuan@intel.com>

更改概述

差异

--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,29 @@
1+*~
2+*.o
3+*.lo
4+*.la
5+*.orig
6+*.rej
7+*.loT
8+*.bin
9+.deps
10+.libs
11+install-sh
12+libtool
13+ltmain.sh
14+missing
15+Makefile
16+Makefile.in
17+config.h
18+config.h.in
19+stamp-h1
20+aclocal.m4
21+autom4te.cache
22+config.guess
23+config.log
24+config.status
25+config.sub
26+configure
27+depcomp
28+fw/msvdx_bin
29+fw/msvdx_fw.bin
--- a/Makefile.am
+++ b/Makefile.am
@@ -31,11 +31,16 @@ SUBDIRS += i965_drv_video
3131 endif
3232
3333 pcfiles = \
34- libva.pc
34+ libva.pc \
35+ libva-$(LIBVA_DISPLAY).pc
36+
37+# libva-<display>.pc - for display-specific dependencies
38+libva-$(LIBVA_DISPLAY).pc: libva_display.pc
39+ @cp $< $@
3540
3641 pkgconfigdir = @pkgconfigdir@
3742 pkgconfig_DATA = $(pcfiles)
3843
39-EXTRA_DIST = libva.pc.in
44+EXTRA_DIST = libva.pc.in libva_display.pc.in
4045
4146 CLEANFILES = $(pcfiles)
--- a/configure.ac
+++ b/configure.ac
@@ -22,8 +22,8 @@
2222
2323 # libva package version number, (as distinct from shared library version)
2424 m4_define([libva_major_version], [0])
25-m4_define([libva_minor_version], [30])
26-m4_define([libva_micro_version], [4])
25+m4_define([libva_minor_version], [31])
26+m4_define([libva_micro_version], [0])
2727
2828 m4_define([libva_version],
2929 [libva_major_version.libva_minor_version.libva_micro_version])
@@ -32,9 +32,9 @@ m4_define([libva_version],
3232 m4_define([libva_sds_version], [2])
3333
3434 # if the library source code has changed, increment revision
35-m4_define([libva_lt_revision], [1])
35+m4_define([libva_lt_revision], [0])
3636 # if any interface was added/removed/changed, then inc current, reset revision
37-m4_define([libva_lt_current], [0])
37+m4_define([libva_lt_current], [1])
3838 # if any interface was added since last public release, then increment age
3939 # if any interface was removed since last public release, then set age to 0
4040 m4_define([libva_lt_age], [0])
@@ -114,8 +114,12 @@ AC_SUBST(LIBVA_LIBS)
114114 pkgconfigdir=${libdir}/pkgconfig
115115 AC_SUBST(pkgconfigdir)
116116
117-libvabackendlib=libva.la
117+LIBVA_DISPLAY=x11
118+libvacorelib=libva.la
119+libvabackendlib=libva-$LIBVA_DISPLAY.la
120+AC_SUBST([libvacorelib])
118121 AC_SUBST([libvabackendlib])
122+AC_SUBST(LIBVA_DISPLAY)
119123
120124 AC_OUTPUT([
121125 Makefile
@@ -130,5 +134,6 @@ AC_OUTPUT([
130134 i965_drv_video/shaders/render/Makefile
131135 test/Makefile
132136 libva.pc
137+ libva_display.pc
133138 ])
134139
--- a/dummy_drv_video/dummy_drv_video.c
+++ b/dummy_drv_video/dummy_drv_video.c
@@ -502,25 +502,8 @@ VAStatus dummy_GetImage(
502502 return VA_STATUS_SUCCESS;
503503 }
504504
505-VAStatus dummy_PutImage(
506- VADriverContextP ctx,
507- VASurfaceID surface,
508- VAImageID image,
509- int src_x,
510- int src_y,
511- unsigned int width,
512- unsigned int height,
513- int dest_x,
514- int dest_y
515-)
516-{
517- INIT_DRIVER_DATA
518-
519- /* TODO */
520- return VA_STATUS_SUCCESS;
521-}
522505
523-VAStatus dummy_PutImage2(
506+VAStatus dummy_PutImage(
524507 VADriverContextP ctx,
525508 VASurfaceID surface,
526509 VAImageID image,
@@ -631,31 +614,8 @@ VAStatus dummy_SetSubpictureGlobalAlpha(
631614 return VA_STATUS_SUCCESS;
632615 }
633616
634-VAStatus dummy_AssociateSubpicture(
635- VADriverContextP ctx,
636- VASubpictureID subpicture,
637- VASurfaceID *target_surfaces,
638- int num_surfaces,
639- short src_x, /* upper left offset in subpicture */
640- short src_y,
641- short dest_x, /* upper left offset in surface */
642- short dest_y,
643- unsigned short width,
644- unsigned short height,
645- /*
646- * whether to enable chroma-keying or global-alpha
647- * see VA_SUBPICTURE_XXX values
648- */
649- unsigned int flags
650-)
651-{
652- INIT_DRIVER_DATA
653-
654- /* TODO */
655- return VA_STATUS_SUCCESS;
656-}
657617
658-VAStatus dummy_AssociateSubpicture2(
618+VAStatus dummy_AssociateSubpicture(
659619 VADriverContextP ctx,
660620 VASubpictureID subpicture,
661621 VASurfaceID *target_surfaces,
@@ -1045,24 +1005,16 @@ VAStatus dummy_EndPicture(
10451005
10461006 VAStatus dummy_SyncSurface(
10471007 VADriverContextP ctx,
1048- VAContextID context,
10491008 VASurfaceID render_target
10501009 )
10511010 {
10521011 INIT_DRIVER_DATA
10531012 VAStatus vaStatus = VA_STATUS_SUCCESS;
1054- object_context_p obj_context;
10551013 object_surface_p obj_surface;
10561014
1057- obj_context = CONTEXT(context);
1058- ASSERT(obj_context);
1059-
10601015 obj_surface = SURFACE(render_target);
10611016 ASSERT(obj_surface);
10621017
1063- /* Assume that this shouldn't be called before vaEndPicture() */
1064- ASSERT( obj_context->current_render_target != obj_surface->base.id );
1065-
10661018 return vaStatus;
10671019 }
10681020
@@ -1258,7 +1210,6 @@ VAStatus __vaDriverInit_0_30( VADriverContextP ctx )
12581210 ctx->vtable.vaSetImagePalette = dummy_SetImagePalette;
12591211 ctx->vtable.vaGetImage = dummy_GetImage;
12601212 ctx->vtable.vaPutImage = dummy_PutImage;
1261- ctx->vtable.vaPutImage2 = dummy_PutImage2;
12621213 ctx->vtable.vaQuerySubpictureFormats = dummy_QuerySubpictureFormats;
12631214 ctx->vtable.vaCreateSubpicture = dummy_CreateSubpicture;
12641215 ctx->vtable.vaDestroySubpicture = dummy_DestroySubpicture;
@@ -1266,7 +1217,6 @@ VAStatus __vaDriverInit_0_30( VADriverContextP ctx )
12661217 ctx->vtable.vaSetSubpictureChromakey = dummy_SetSubpictureChromakey;
12671218 ctx->vtable.vaSetSubpictureGlobalAlpha = dummy_SetSubpictureGlobalAlpha;
12681219 ctx->vtable.vaAssociateSubpicture = dummy_AssociateSubpicture;
1269- ctx->vtable.vaAssociateSubpicture2 = dummy_AssociateSubpicture2;
12701220 ctx->vtable.vaDeassociateSubpicture = dummy_DeassociateSubpicture;
12711221 ctx->vtable.vaQueryDisplayAttributes = dummy_QueryDisplayAttributes;
12721222 ctx->vtable.vaGetDisplayAttributes = dummy_GetDisplayAttributes;
--- a/i965_drv_video/Makefile.am
+++ b/i965_drv_video/Makefile.am
@@ -27,7 +27,7 @@ AM_CFLAGS = -Wall -I$(top_srcdir)/src -I$(top_srcdir)/src/x11 @DRM_CFLAGS@ -DIN_
2727 i965_drv_video_la_LTLIBRARIES = i965_drv_video.la
2828 i965_drv_video_ladir = @LIBVA_DRIVERS_PATH@
2929 i965_drv_video_la_LDFLAGS = -module -avoid-version -no-undefined -Wl,--no-undefined @DRM_LIBS@ -ldrm_intel
30-i965_drv_video_la_LIBADD = ../src/libva.la -lpthread
30+i965_drv_video_la_LIBADD = ../src/libva-x11.la -lpthread
3131
3232 i965_drv_video_la_SOURCES = \
3333 object_heap.c \
--- a/i965_drv_video/i965_drv_video.c
+++ b/i965_drv_video/i965_drv_video.c
@@ -350,7 +350,7 @@ i965_QueryImageFormats(VADriverContextP ctx,
350350 }
351351
352352 VAStatus
353-i965_PutImage2(VADriverContextP ctx,
353+i965_PutImage(VADriverContextP ctx,
354354 VASurfaceID surface,
355355 VAImageID image,
356356 int src_x,
@@ -480,8 +480,12 @@ i965_AssociateSubpicture(VADriverContextP ctx,
480480 int num_surfaces,
481481 short src_x, /* upper left offset in subpicture */
482482 short src_y,
483+ unsigned short src_width,
484+ unsigned short src_height,
483485 short dest_x, /* upper left offset in surface */
484486 short dest_y,
487+ unsigned short dest_width,
488+ unsigned short dest_height,
485489 unsigned short width,
486490 unsigned short height,
487491 /*
@@ -510,27 +514,6 @@ i965_AssociateSubpicture(VADriverContextP ctx,
510514 return VA_STATUS_SUCCESS;
511515 }
512516
513-VAStatus
514-i965_AssociateSubpicture2(VADriverContextP ctx,
515- VASubpictureID subpicture,
516- VASurfaceID *target_surfaces,
517- int num_surfaces,
518- short src_x, /* upper left offset in subpicture */
519- short src_y,
520- unsigned short src_width,
521- unsigned short src_height,
522- short dest_x, /* upper left offset in surface */
523- short dest_y,
524- unsigned short dest_width,
525- unsigned short dest_height,
526- /*
527- * whether to enable chroma-keying or global-alpha
528- * see VA_SUBPICTURE_XXX values
529- */
530- unsigned int flags)
531-{
532- return VA_STATUS_SUCCESS;
533-}
534517
535518 VAStatus
536519 i965_DeassociateSubpicture(VADriverContextP ctx,
@@ -1012,19 +995,13 @@ i965_EndPicture(VADriverContextP ctx, VAContextID context)
1012995
1013996 VAStatus
1014997 i965_SyncSurface(VADriverContextP ctx,
1015- VAContextID context,
1016998 VASurfaceID render_target)
1017999 {
10181000 struct i965_driver_data *i965 = i965_driver_data(ctx);
1019- struct object_context *obj_context = CONTEXT(context);
10201001 struct object_surface *obj_surface = SURFACE(render_target);
10211002
1022- assert(obj_context);
10231003 assert(obj_surface);
10241004
1025- /* Assume that this shouldn't be called before vaEndPicture() */
1026- assert(obj_context->decode_state.current_render_target != render_target);
1027-
10281005 return VA_STATUS_SUCCESS;
10291006 }
10301007
@@ -1226,20 +1203,6 @@ i965_GetImage(VADriverContextP ctx,
12261203 }
12271204
12281205 VAStatus
1229-i965_PutImage(VADriverContextP ctx,
1230- VASurfaceID surface,
1231- VAImageID image,
1232- int src_x,
1233- int src_y,
1234- unsigned int width,
1235- unsigned int height,
1236- int dest_x,
1237- int dest_y)
1238-{
1239- return VA_STATUS_SUCCESS;
1240-}
1241-
1242-VAStatus
12431206 i965_PutSurface(VADriverContextP ctx,
12441207 VASurfaceID surface,
12451208 Drawable draw, /* X Drawable */
@@ -1394,7 +1357,6 @@ __vaDriverInit_0_30( VADriverContextP ctx )
13941357 ctx->vtable.vaSetImagePalette = i965_SetImagePalette;
13951358 ctx->vtable.vaGetImage = i965_GetImage;
13961359 ctx->vtable.vaPutImage = i965_PutImage;
1397- ctx->vtable.vaPutImage2 = i965_PutImage2;
13981360 ctx->vtable.vaQuerySubpictureFormats = i965_QuerySubpictureFormats;
13991361 ctx->vtable.vaCreateSubpicture = i965_CreateSubpicture;
14001362 ctx->vtable.vaDestroySubpicture = i965_DestroySubpicture;
@@ -1403,7 +1365,6 @@ __vaDriverInit_0_30( VADriverContextP ctx )
14031365 ctx->vtable.vaSetSubpictureChromakey = i965_SetSubpictureChromakey;
14041366 ctx->vtable.vaSetSubpictureGlobalAlpha = i965_SetSubpictureGlobalAlpha;
14051367 ctx->vtable.vaAssociateSubpicture = i965_AssociateSubpicture;
1406- ctx->vtable.vaAssociateSubpicture2 = i965_AssociateSubpicture2;
14071368 ctx->vtable.vaDeassociateSubpicture = i965_DeassociateSubpicture;
14081369 ctx->vtable.vaQueryDisplayAttributes = i965_QueryDisplayAttributes;
14091370 ctx->vtable.vaGetDisplayAttributes = i965_GetDisplayAttributes;
--- /dev/null
+++ b/libva_display.pc.in
@@ -0,0 +1,11 @@
1+prefix=@prefix@
2+exec_prefix=@exec_prefix@
3+libdir=@libdir@
4+includedir=@includedir@
5+display=@LIBVA_DISPLAY@
6+
7+Name: libva-${display}
8+Description: Userspace Video Acceleration (VA) ${display} interface
9+Version: @PACKAGE_VERSION@
10+Libs: -L${libdir} -lva-${display}
11+Cflags: -I${includedir}
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -28,10 +28,18 @@ INCLUDES = \
2828 LDADD = \
2929 $(LIBVA_LT_LDFLAGS)
3030
31-libva_la_LTLIBRARIES = libva.la
31+lib_LTLIBRARIES = \
32+ libva.la \
33+ libva-x11.la
34+
3235 libva_ladir = $(libdir)
3336 libva_la_LDFLAGS = $(LDADD) -no-undefined
34-libva_la_LIBADD = $(LIBVA_LIBS) -ldl -lX11 -lXext x11/libva_x11.la -ldrm -lXfixes
37+libva_la_LIBADD = $(LIBVA_LIBS) -ldl
38+
39+libva_x11_la_SOURCES =
40+libva_x11_la_LIBADD = $(libvacorelib) x11/libva_x11.la $(LIBVA_LIBS) $(X11_LIBS) $(XEXT_LIBS) $(DRM_LIBS) $(XFIXES_LIBS)
41+libva_x11_la_LDFLAGS = $(LDADD)
42+libva_x11_la_DEPENDENCIES = $(libvacorelib)
3543
3644 SUBDIRS = x11
3745
--- a/src/va.c
+++ b/src/va.c
@@ -56,7 +56,11 @@
5656
5757 static int va_debug_trace = 0;
5858
59-int vaDisplayIsValid(VADisplay dpy);
59+static int vaDisplayIsValid(VADisplay dpy)
60+{
61+ VADisplayContextP pDisplayContext = (VADisplayContextP)dpy;
62+ return pDisplayContext && pDisplayContext->vaIsValid(pDisplayContext);
63+}
6064
6165 static void va_errorMessage(const char *msg, ...)
6266 {
@@ -217,7 +221,6 @@ static VAStatus va_openDriver(VADisplay dpy, char *driver_name)
217221 CHECK_VTABLE(vaStatus, ctx, SetImagePalette);
218222 CHECK_VTABLE(vaStatus, ctx, GetImage);
219223 CHECK_VTABLE(vaStatus, ctx, PutImage);
220- CHECK_VTABLE(vaStatus, ctx, PutImage2);
221224 CHECK_VTABLE(vaStatus, ctx, QuerySubpictureFormats);
222225 CHECK_VTABLE(vaStatus, ctx, CreateSubpicture);
223226 CHECK_VTABLE(vaStatus, ctx, DestroySubpicture);
@@ -225,7 +228,6 @@ static VAStatus va_openDriver(VADisplay dpy, char *driver_name)
225228 CHECK_VTABLE(vaStatus, ctx, SetSubpictureChromakey);
226229 CHECK_VTABLE(vaStatus, ctx, SetSubpictureGlobalAlpha);
227230 CHECK_VTABLE(vaStatus, ctx, AssociateSubpicture);
228- CHECK_VTABLE(vaStatus, ctx, AssociateSubpicture2);
229231 CHECK_VTABLE(vaStatus, ctx, DeassociateSubpicture);
230232 CHECK_VTABLE(vaStatus, ctx, QueryDisplayAttributes);
231233 CHECK_VTABLE(vaStatus, ctx, GetDisplayAttributes);
@@ -707,7 +709,6 @@ VAStatus vaEndPicture (
707709
708710 VAStatus vaSyncSurface (
709711 VADisplay dpy,
710- VAContextID context,
711712 VASurfaceID render_target
712713 )
713714 {
@@ -716,7 +717,7 @@ VAStatus vaSyncSurface (
716717 ctx = CTX(dpy);
717718
718719 TRACE(vaSyncSurface);
719- return ctx->vtable.vaSyncSurface( ctx, context, render_target );
720+ return ctx->vtable.vaSyncSurface( ctx, render_target );
720721 }
721722
722723 VAStatus vaQuerySurfaceStatus (
@@ -871,30 +872,6 @@ VAStatus vaPutImage (
871872 VAImageID image,
872873 int src_x,
873874 int src_y,
874- unsigned int width,
875- unsigned int height,
876- int dest_x,
877- int dest_y
878-)
879-{
880- VADriverContextP ctx;
881- CHECK_DISPLAY(dpy);
882- ctx = CTX(dpy);
883-
884- TRACE(vaPutImage);
885- return ctx->vtable.vaPutImage ( ctx, surface, image, src_x, src_y, width, height, dest_x, dest_y );
886-}
887-
888-/*
889- * Similar to vaPutImage but with additional destination width
890- * and height arguments to enable scaling
891- */
892-VAStatus vaPutImage2 (
893- VADisplay dpy,
894- VASurfaceID surface,
895- VAImageID image,
896- int src_x,
897- int src_y,
898875 unsigned int src_width,
899876 unsigned int src_height,
900877 int dest_x,
@@ -907,8 +884,8 @@ VAStatus vaPutImage2 (
907884 CHECK_DISPLAY(dpy);
908885 ctx = CTX(dpy);
909886
910- TRACE(vaPutImage2);
911- return ctx->vtable.vaPutImage2 ( ctx, surface, image, src_x, src_y, src_width, src_height, dest_x, dest_y, dest_width, dest_height );
887+ TRACE(vaPutImage);
888+ return ctx->vtable.vaPutImage ( ctx, surface, image, src_x, src_y, src_width, src_height, dest_x, dest_y, dest_width, dest_height );
912889 }
913890
914891 /*
@@ -1092,32 +1069,6 @@ VAStatus vaAssociateSubpicture (
10921069 int num_surfaces,
10931070 short src_x, /* upper left offset in subpicture */
10941071 short src_y,
1095- short dest_x, /* upper left offset in surface */
1096- short dest_y,
1097- unsigned short width,
1098- unsigned short height,
1099- /*
1100- * whether to enable chroma-keying or global-alpha
1101- * see VA_SUBPICTURE_XXX values
1102- */
1103- unsigned int flags
1104-)
1105-{
1106- VADriverContextP ctx;
1107- CHECK_DISPLAY(dpy);
1108- ctx = CTX(dpy);
1109-
1110- TRACE(vaAssociateSubpicture);
1111- return ctx->vtable.vaAssociateSubpicture ( ctx, subpicture, target_surfaces, num_surfaces, src_x, src_y, dest_x, dest_y, width, height, flags );
1112-}
1113-
1114-VAStatus vaAssociateSubpicture2 (
1115- VADisplay dpy,
1116- VASubpictureID subpicture,
1117- VASurfaceID *target_surfaces,
1118- int num_surfaces,
1119- short src_x, /* upper left offset in subpicture */
1120- short src_y,
11211072 unsigned short src_width,
11221073 unsigned short src_height,
11231074 short dest_x, /* upper left offset in surface */
@@ -1135,8 +1086,8 @@ VAStatus vaAssociateSubpicture2 (
11351086 CHECK_DISPLAY(dpy);
11361087 ctx = CTX(dpy);
11371088
1138- TRACE(vaAssociateSubpicture2);
1139- return ctx->vtable.vaAssociateSubpicture2 ( ctx, subpicture, target_surfaces, num_surfaces, src_x, src_y, src_width, src_height, dest_x, dest_y, dest_width, dest_height, flags );
1089+ TRACE(vaAssociateSubpicture);
1090+ return ctx->vtable.vaAssociateSubpicture ( ctx, subpicture, target_surfaces, num_surfaces, src_x, src_y, src_width, src_height, dest_x, dest_y, dest_width, dest_height, flags );
11401091 }
11411092
11421093 /*
--- a/src/va.h
+++ b/src/va.h
@@ -125,6 +125,7 @@ typedef int VAStatus; /* Return status type from functions */
125125 #define VA_STATUS_ERROR_FLAG_NOT_SUPPORTED 0x00000011
126126 #define VA_STATUS_ERROR_INVALID_PARAMETER 0x00000012
127127 #define VA_STATUS_ERROR_RESOLUTION_NOT_SUPPORTED 0x00000013
128+#define VA_STATUS_ERROR_UNIMPLEMENTED 0x00000014
128129 #define VA_STATUS_ERROR_UNKNOWN 0xFFFFFFFF
129130
130131 /*
@@ -572,7 +573,7 @@ typedef struct _VAMacroblockParameterBufferMPEG2
572573 unsigned int field_motion_type : 2;
573574 unsigned int dct_type : 1;
574575 } bits;
575- unsigned char value;
576+ unsigned int value;
576577 } macroblock_modes;
577578 unsigned char motion_vertical_field_select;
578579 /*
@@ -626,18 +627,18 @@ typedef struct _VAPictureParameterBufferMPEG4
626627 VASurfaceID backward_reference_picture;
627628 union {
628629 struct {
629- unsigned char short_video_header : 1;
630- unsigned char chroma_format : 2;
631- unsigned char interlaced : 1;
632- unsigned char obmc_disable : 1;
633- unsigned char sprite_enable : 2;
634- unsigned char sprite_warping_accuracy : 2;
635- unsigned char quant_type : 1;
636- unsigned char quarter_sample : 1;
637- unsigned char data_partitioned : 1;
638- unsigned char reversible_vlc : 1;
630+ unsigned int short_video_header : 1;
631+ unsigned int chroma_format : 2;
632+ unsigned int interlaced : 1;
633+ unsigned int obmc_disable : 1;
634+ unsigned int sprite_enable : 2;
635+ unsigned int sprite_warping_accuracy : 2;
636+ unsigned int quant_type : 1;
637+ unsigned int quarter_sample : 1;
638+ unsigned int data_partitioned : 1;
639+ unsigned int reversible_vlc : 1;
639640 } bits;
640- unsigned short value;
641+ unsigned int value;
641642 } vol_fields;
642643 unsigned char no_of_sprite_warping_points;
643644 short sprite_trajectory_du[3];
@@ -645,14 +646,14 @@ typedef struct _VAPictureParameterBufferMPEG4
645646 unsigned char quant_precision;
646647 union {
647648 struct {
648- unsigned char vop_coding_type : 2;
649- unsigned char backward_reference_vop_coding_type : 2;
650- unsigned char vop_rounding_type : 1;
651- unsigned char intra_dc_vlc_thr : 3;
652- unsigned char top_field_first : 1;
653- unsigned char alternate_vertical_scan_flag : 1;
649+ unsigned int vop_coding_type : 2;
650+ unsigned int backward_reference_vop_coding_type : 2;
651+ unsigned int vop_rounding_type : 1;
652+ unsigned int intra_dc_vlc_thr : 3;
653+ unsigned int top_field_first : 1;
654+ unsigned int alternate_vertical_scan_flag : 1;
654655 } bits;
655- unsigned short value;
656+ unsigned int value;
656657 } vop_fields;
657658 unsigned char vop_fcode_forward;
658659 unsigned char vop_fcode_backward;
@@ -722,28 +723,41 @@ typedef struct _VAPictureParameterBufferVC1
722723 /* sequence layer for AP or meta data for SP and MP */
723724 union {
724725 struct {
725- unsigned char interlace : 1; /* SEQUENCE_LAYER::INTERLACE */
726- unsigned char syncmarker : 1;/* METADATA::SYNCMARKER */
727- unsigned char overlap : 1;/* METADATA::OVERLAP */
726+ unsigned int pulldown : 1; /* SEQUENCE_LAYER::PULLDOWN */
727+ unsigned int interlace : 1; /* SEQUENCE_LAYER::INTERLACE */
728+ unsigned int tfcntrflag : 1; /* SEQUENCE_LAYER::TFCNTRFLAG */
729+ unsigned int finterpflag : 1; /* SEQUENCE_LAYER::FINTERPFLAG */
730+ unsigned int psf : 1; /* SEQUENCE_LAYER::PSF */
731+ unsigned int multires : 1; /* METADATA::MULTIRES */
732+ unsigned int overlap : 1; /* METADATA::OVERLAP */
733+ unsigned int syncmarker : 1; /* METADATA::SYNCMARKER */
734+ unsigned int rangered : 1; /* METADATA::RANGERED */
735+ unsigned int max_b_frames : 3; /* METADATA::MAXBFRAMES */
728736 } bits;
729- unsigned char value;
737+ unsigned int value;
730738 } sequence_fields;
731739
732740 unsigned short coded_width; /* ENTRY_POINT_LAYER::CODED_WIDTH */
733741 unsigned short coded_height; /* ENTRY_POINT_LAYER::CODED_HEIGHT */
734- unsigned char closed_entry; /* ENTRY_POINT_LAYER::CLOSED_ENTRY */
735- unsigned char broken_link; /* ENTRY_POINT_LAYER::BROKEN_LINK */
736- unsigned char loopfilter; /* ENTRY_POINT_LAYER::LOOPFILTER */
742+ union {
743+ struct {
744+ unsigned int broken_link : 1; /* ENTRY_POINT_LAYER::BROKEN_LINK */
745+ unsigned int closed_entry : 1; /* ENTRY_POINT_LAYER::CLOSED_ENTRY */
746+ unsigned int panscan_flag : 1; /* ENTRY_POINT_LAYER::PANSCAN_FLAG */
747+ unsigned int loopfilter : 1; /* ENTRY_POINT_LAYER::LOOPFILTER */
748+ } bits;
749+ unsigned int value;
750+ } entrypoint_fields;
737751 unsigned char conditional_overlap_flag; /* ENTRY_POINT_LAYER::CONDOVER */
738752 unsigned char fast_uvmc_flag; /* ENTRY_POINT_LAYER::FASTUVMC */
739753 union {
740754 struct {
741- unsigned char luma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPY_FLAG */
742- unsigned char luma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPY */
743- unsigned char chroma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPUV_FLAG */
744- unsigned char chroma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPUV */
755+ unsigned int luma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPY_FLAG */
756+ unsigned int luma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPY */
757+ unsigned int chroma_flag : 1; /* ENTRY_POINT_LAYER::RANGE_MAPUV_FLAG */
758+ unsigned int chroma : 3; /* ENTRY_POINT_LAYER::RANGE_MAPUV */
745759 } bits;
746- unsigned char value;
760+ unsigned int value;
747761 } range_mapping_fields;
748762
749763 unsigned char b_picture_fraction; /* PICTURE_LAYER::BFRACTION */
@@ -757,88 +771,88 @@ typedef struct _VAPictureParameterBufferVC1
757771 unsigned char luma_shift; /* PICTURE_LAYER::LUMSHIFT */
758772 union {
759773 struct {
760- unsigned char picture_type : 2; /* PICTURE_LAYER::PTYPE */
761- unsigned char frame_coding_mode : 3; /* PICTURE_LAYER::FCM */
762- unsigned char top_field_first : 1; /* PICTURE_LAYER::TFF */
763- unsigned char is_first_field : 1; /* set to 1 if it is the first field */
764- unsigned char intensity_compensation : 1; /* PICTURE_LAYER::INTCOMP */
774+ unsigned int picture_type : 3; /* PICTURE_LAYER::PTYPE */
775+ unsigned int frame_coding_mode : 3; /* PICTURE_LAYER::FCM */
776+ unsigned int top_field_first : 1; /* PICTURE_LAYER::TFF */
777+ unsigned int is_first_field : 1; /* set to 1 if it is the first field */
778+ unsigned int intensity_compensation : 1; /* PICTURE_LAYER::INTCOMP */
765779 } bits;
766- unsigned char value;
780+ unsigned int value;
767781 } picture_fields;
768782 union {
769783 struct {
770- unsigned char mv_type_mb : 1; /* PICTURE::MVTYPEMB */
771- unsigned char direct_mb : 1; /* PICTURE::DIRECTMB */
772- unsigned char skip_mb : 1; /* PICTURE::SKIPMB */
773- unsigned char field_tx : 1; /* PICTURE::FIELDTX */
774- unsigned char forward_mb : 1; /* PICTURE::FORWARDMB */
775- unsigned char ac_pred : 1; /* PICTURE::ACPRED */
776- unsigned char overflags : 1; /* PICTURE::OVERFLAGS */
784+ unsigned int mv_type_mb : 1; /* PICTURE::MVTYPEMB */
785+ unsigned int direct_mb : 1; /* PICTURE::DIRECTMB */
786+ unsigned int skip_mb : 1; /* PICTURE::SKIPMB */
787+ unsigned int field_tx : 1; /* PICTURE::FIELDTX */
788+ unsigned int forward_mb : 1; /* PICTURE::FORWARDMB */
789+ unsigned int ac_pred : 1; /* PICTURE::ACPRED */
790+ unsigned int overflags : 1; /* PICTURE::OVERFLAGS */
777791 } flags;
778- unsigned char value;
792+ unsigned int value;
779793 } raw_coding;
780794 union {
781795 struct {
782- unsigned char bp_mv_type_mb : 1; /* PICTURE::MVTYPEMB */
783- unsigned char bp_direct_mb : 1; /* PICTURE::DIRECTMB */
784- unsigned char bp_skip_mb : 1; /* PICTURE::SKIPMB */
785- unsigned char bp_field_tx : 1; /* PICTURE::FIELDTX */
786- unsigned char bp_forward_mb : 1; /* PICTURE::FORWARDMB */
787- unsigned char bp_ac_pred : 1; /* PICTURE::ACPRED */
788- unsigned char bp_overflags : 1; /* PICTURE::OVERFLAGS */
796+ unsigned int bp_mv_type_mb : 1; /* PICTURE::MVTYPEMB */
797+ unsigned int bp_direct_mb : 1; /* PICTURE::DIRECTMB */
798+ unsigned int bp_skip_mb : 1; /* PICTURE::SKIPMB */
799+ unsigned int bp_field_tx : 1; /* PICTURE::FIELDTX */
800+ unsigned int bp_forward_mb : 1; /* PICTURE::FORWARDMB */
801+ unsigned int bp_ac_pred : 1; /* PICTURE::ACPRED */
802+ unsigned int bp_overflags : 1; /* PICTURE::OVERFLAGS */
789803 } flags;
790- unsigned char value;
804+ unsigned int value;
791805 } bitplane_present; /* signal what bitplane is being passed via the bitplane buffer */
792806 union {
793807 struct {
794- unsigned char reference_distance_flag : 1;/* PICTURE_LAYER::REFDIST_FLAG */
795- unsigned char reference_distance : 5;/* PICTURE_LAYER::REFDIST */
796- unsigned char num_reference_pictures: 1;/* PICTURE_LAYER::NUMREF */
797- unsigned char reference_field_pic_indicator : 1;/* PICTURE_LAYER::REFFIELD */
808+ unsigned int reference_distance_flag : 1;/* PICTURE_LAYER::REFDIST_FLAG */
809+ unsigned int reference_distance : 5;/* PICTURE_LAYER::REFDIST */
810+ unsigned int num_reference_pictures: 1;/* PICTURE_LAYER::NUMREF */
811+ unsigned int reference_field_pic_indicator : 1;/* PICTURE_LAYER::REFFIELD */
798812 } bits;
799- unsigned short value;
813+ unsigned int value;
800814 } reference_fields;
801815 union {
802816 struct {
803- unsigned char mv_mode : 3; /* PICTURE_LAYER::MVMODE */
804- unsigned char mv_mode2 : 3; /* PICTURE_LAYER::MVMODE2 */
805- unsigned char mv_table : 3; /* PICTURE_LAYER::MVTAB/IMVTAB */
806- unsigned char two_mv_block_pattern_table: 2; /* PICTURE_LAYER::2MVBPTAB */
807- unsigned char four_mv_switch : 1; /* PICTURE_LAYER::4MVSWITCH */
808- unsigned char four_mv_block_pattern_table : 2; /* PICTURE_LAYER::4MVBPTAB */
809- unsigned char extended_mv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_MV */
810- unsigned char extended_mv_range : 2; /* PICTURE_LAYER::MVRANGE */
811- unsigned char extended_dmv_flag : 1; /* ENTRY_POCHAR_LAYER::EXTENDED_DMV */
812- unsigned char extended_dmv_range : 2; /* PICTURE_LAYER::DMVRANGE */
817+ unsigned int mv_mode : 3; /* PICTURE_LAYER::MVMODE */
818+ unsigned int mv_mode2 : 3; /* PICTURE_LAYER::MVMODE2 */
819+ unsigned int mv_table : 3; /* PICTURE_LAYER::MVTAB/IMVTAB */
820+ unsigned int two_mv_block_pattern_table: 2; /* PICTURE_LAYER::2MVBPTAB */
821+ unsigned int four_mv_switch : 1; /* PICTURE_LAYER::4MVSWITCH */
822+ unsigned int four_mv_block_pattern_table : 2; /* PICTURE_LAYER::4MVBPTAB */
823+ unsigned int extended_mv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_MV */
824+ unsigned int extended_mv_range : 2; /* PICTURE_LAYER::MVRANGE */
825+ unsigned int extended_dmv_flag : 1; /* ENTRY_POINT_LAYER::EXTENDED_DMV */
826+ unsigned int extended_dmv_range : 2; /* PICTURE_LAYER::DMVRANGE */
813827 } bits;
814828 unsigned int value;
815829 } mv_fields;
816830 union {
817831 struct {
818- unsigned char dquant : 2; /* ENTRY_POINT_LAYER::DQUANT */
819- unsigned char quantizer : 2; /* ENTRY_POINT_LAYER::QUANTIZER */
820- unsigned char half_qp : 1; /* PICTURE_LAYER::HALFQP */
821- unsigned char pic_quantizer_scale : 5;/* PICTURE_LAYER::PQUANT */
822- unsigned char pic_quantizer_type : 1;/* PICTURE_LAYER::PQUANTIZER */
823- unsigned char dq_frame : 1; /* VOPDQUANT::DQUANTFRM */
824- unsigned char dq_profile : 2; /* VOPDQUANT::DQPROFILE */
825- unsigned char dq_sb_edge : 2; /* VOPDQUANT::DQSBEDGE */
826- unsigned char dq_db_edge : 2; /* VOPDQUANT::DQDBEDGE */
827- unsigned char dq_binary_level : 1; /* VOPDQUANT::DQBILEVEL */
828- unsigned char alt_pic_quantizer : 5;/* VOPDQUANT::ALTPQUANT */
832+ unsigned int dquant : 2; /* ENTRY_POINT_LAYER::DQUANT */
833+ unsigned int quantizer : 2; /* ENTRY_POINT_LAYER::QUANTIZER */
834+ unsigned int half_qp : 1; /* PICTURE_LAYER::HALFQP */
835+ unsigned int pic_quantizer_scale : 5;/* PICTURE_LAYER::PQUANT */
836+ unsigned int pic_quantizer_type : 1;/* PICTURE_LAYER::PQUANTIZER */
837+ unsigned int dq_frame : 1; /* VOPDQUANT::DQUANTFRM */
838+ unsigned int dq_profile : 2; /* VOPDQUANT::DQPROFILE */
839+ unsigned int dq_sb_edge : 2; /* VOPDQUANT::DQSBEDGE */
840+ unsigned int dq_db_edge : 2; /* VOPDQUANT::DQDBEDGE */
841+ unsigned int dq_binary_level : 1; /* VOPDQUANT::DQBILEVEL */
842+ unsigned int alt_pic_quantizer : 5;/* VOPDQUANT::ALTPQUANT */
829843 } bits;
830- unsigned long value;
844+ unsigned int value;
831845 } pic_quantizer_fields;
832846 union {
833847 struct {
834- unsigned char variable_sized_transform_flag : 1;/* ENTRY_POINT_LAYER::VSTRANSFORM */
835- unsigned char mb_level_transform_type_flag : 1;/* PICTURE_LAYER::TTMBF */
836- unsigned char frame_level_transform_type : 2;/* PICTURE_LAYER::TTFRM */
837- unsigned char transform_ac_codingset_idx1 : 2;/* PICTURE_LAYER::TRANSACFRM */
838- unsigned char transform_ac_codingset_idx2 : 2;/* PICTURE_LAYER::TRANSACFRM2 */
839- unsigned char intra_transform_dc_table : 1;/* PICTURE_LAYER::TRANSDCTAB */
848+ unsigned int variable_sized_transform_flag : 1;/* ENTRY_POINT_LAYER::VSTRANSFORM */
849+ unsigned int mb_level_transform_type_flag : 1;/* PICTURE_LAYER::TTMBF */
850+ unsigned int frame_level_transform_type : 2;/* PICTURE_LAYER::TTFRM */
851+ unsigned int transform_ac_codingset_idx1 : 2;/* PICTURE_LAYER::TRANSACFRM */
852+ unsigned int transform_ac_codingset_idx2 : 2;/* PICTURE_LAYER::TRANSACFRM2 */
853+ unsigned int intra_transform_dc_table : 1;/* PICTURE_LAYER::TRANSDCTAB */
840854 } bits;
841- unsigned short value;
855+ unsigned int value;
842856 } transform_fields;
843857 } VAPictureParameterBufferVC1;
844858
@@ -882,6 +896,7 @@ This is simplely a buffer containing raw bit-stream bytes
882896 typedef struct _VAPictureH264
883897 {
884898 VASurfaceID picture_id;
899+ unsigned int frame_idx;
885900 unsigned int flags;
886901 unsigned int TopFieldOrderCnt;
887902 unsigned int BottomFieldOrderCnt;
@@ -909,30 +924,41 @@ typedef struct _VAPictureParameterBufferH264
909924 unsigned char num_ref_frames;
910925 union {
911926 struct {
912- unsigned char chroma_format_idc : 2;
913- unsigned char residual_colour_transform_flag : 1;
914- unsigned char frame_mbs_only_flag : 1;
915- unsigned char mb_adaptive_frame_field_flag : 1;
916- unsigned char direct_8x8_inference_flag : 1;
917- unsigned char MinLumaBiPredSize8x8 : 1; /* see A.3.3.2 */
927+ unsigned int chroma_format_idc : 2;
928+ unsigned int residual_colour_transform_flag : 1;
929+ unsigned int gaps_in_frame_num_value_allowed_flag : 1;
930+ unsigned int frame_mbs_only_flag : 1;
931+ unsigned int mb_adaptive_frame_field_flag : 1;
932+ unsigned int direct_8x8_inference_flag : 1;
933+ unsigned int MinLumaBiPredSize8x8 : 1; /* see A.3.3.2 */
934+ unsigned int log2_max_frame_num_minus4 : 4;
935+ unsigned int pic_order_cnt_type : 2;
936+ unsigned int log2_max_pic_order_cnt_lsb_minus4 : 4;
937+ unsigned int delta_pic_order_always_zero_flag : 1;
918938 } bits;
919- unsigned char value;
939+ unsigned int value;
920940 } seq_fields;
921941 unsigned char num_slice_groups_minus1;
922942 unsigned char slice_group_map_type;
943+ unsigned short slice_group_change_rate_minus1;
923944 signed char pic_init_qp_minus26;
945+ signed char pic_init_qs_minus26;
924946 signed char chroma_qp_index_offset;
925947 signed char second_chroma_qp_index_offset;
926948 union {
927949 struct {
928- unsigned char entropy_coding_mode_flag : 1;
929- unsigned char weighted_pred_flag : 1;
930- unsigned char weighted_bipred_idc : 2;
931- unsigned char transform_8x8_mode_flag : 1;
932- unsigned char field_pic_flag : 1;
933- unsigned char constrained_intra_pred_flag : 1;
950+ unsigned int entropy_coding_mode_flag : 1;
951+ unsigned int weighted_pred_flag : 1;
952+ unsigned int weighted_bipred_idc : 2;
953+ unsigned int transform_8x8_mode_flag : 1;
954+ unsigned int field_pic_flag : 1;
955+ unsigned int constrained_intra_pred_flag : 1;
956+ unsigned int pic_order_present_flag : 1;
957+ unsigned int deblocking_filter_control_present_flag : 1;
958+ unsigned int redundant_pic_cnt_present_flag : 1;
959+ unsigned int reference_pic_flag : 1; /* nal_ref_idc != 0 */
934960 } bits;
935- unsigned char value;
961+ unsigned int value;
936962 } pic_fields;
937963 unsigned short frame_num;
938964 } VAPictureParameterBufferH264;
@@ -1006,10 +1032,10 @@ typedef struct _VAEncSliceParameterBuffer
10061032 unsigned int slice_height; /* slice height measured in MB */
10071033 union {
10081034 struct {
1009- unsigned char is_intra : 1;
1010- unsigned char disable_deblocking_filter_idc : 2;
1035+ unsigned int is_intra : 1;
1036+ unsigned int disable_deblocking_filter_idc : 2;
10111037 } bits;
1012- unsigned char value;
1038+ unsigned int value;
10131039 } slice_flags;
10141040 } VAEncSliceParameterBuffer;
10151041
@@ -1218,18 +1244,17 @@ Synchronization
12181244 */
12191245 VAStatus vaSyncSurface (
12201246 VADisplay dpy,
1221- VAContextID context,
12221247 VASurfaceID render_target
12231248 );
12241249
12251250 typedef enum
12261251 {
1227- VASurfaceRendering = 0, /* Rendering in progress */
1228- VASurfaceDisplaying = 1, /* Displaying in progress (not safe to render into it) */
1252+ VASurfaceRendering = 1, /* Rendering in progress */
1253+ VASurfaceDisplaying = 2, /* Displaying in progress (not safe to render into it) */
12291254 /* this status is useful if surface is used as the source */
12301255 /* of an overlay */
1231- VASurfaceReady = 2, /* not being rendered or displayed */
1232- VASurfaceSkipped = 4 /* Indicate a skipped frame during encode */
1256+ VASurfaceReady = 4, /* not being rendered or displayed */
1257+ VASurfaceSkipped = 8 /* Indicate a skipped frame during encode */
12331258 } VASurfaceStatus;
12341259
12351260 /*
@@ -1394,8 +1419,6 @@ VAStatus vaGetImage (
13941419 * Image must be in a format supported by the implementation
13951420 * Returns a VA_STATUS_ERROR_SURFACE_BUSY if the surface
13961421 * shouldn't be rendered into when this is called
1397- * The source and destionation width and height are the same and
1398- * no scaling is performed with this operation.
13991422 */
14001423 VAStatus vaPutImage (
14011424 VADisplay dpy,
@@ -1403,22 +1426,6 @@ VAStatus vaPutImage (
14031426 VAImageID image,
14041427 int src_x,
14051428 int src_y,
1406- unsigned int width,
1407- unsigned int height,
1408- int dest_x,
1409- int dest_y
1410-);
1411-
1412-/*
1413- * Similar to vaPutImage but with additional destination width
1414- * and height arguments to enable scaling
1415- */
1416-VAStatus vaPutImage2 (
1417- VADisplay dpy,
1418- VASurfaceID surface,
1419- VAImageID image,
1420- int src_x,
1421- int src_y,
14221429 unsigned int src_width,
14231430 unsigned int src_height,
14241431 int dest_x,
@@ -1567,28 +1574,6 @@ VAStatus vaAssociateSubpicture (
15671574 int num_surfaces,
15681575 short src_x, /* upper left offset in subpicture */
15691576 short src_y,
1570- short dest_x, /* upper left offset in surface */
1571- short dest_y,
1572- unsigned short width,
1573- unsigned short height,
1574- /*
1575- * whether to enable chroma-keying or global-alpha
1576- * see VA_SUBPICTURE_XXX values
1577- */
1578- unsigned int flags
1579-);
1580-
1581-/*
1582- * Similar to vaAssociateSubpicture but with additional destination width
1583- * and height to enable scaling
1584- */
1585-VAStatus vaAssociateSubpicture2 (
1586- VADisplay dpy,
1587- VASubpictureID subpicture,
1588- VASurfaceID *target_surfaces,
1589- int num_surfaces,
1590- short src_x, /* upper left offset in subpicture */
1591- short src_y,
15921577 unsigned short src_width,
15931578 unsigned short src_height,
15941579 short dest_x, /* upper left offset in surface */
--- a/src/va_backend.h
+++ b/src/va_backend.h
@@ -175,7 +175,6 @@ struct VADriverVTable
175175
176176 VAStatus (*vaSyncSurface) (
177177 VADriverContextP ctx,
178- VAContextID context,
179178 VASurfaceID render_target
180179 );
181180
@@ -254,18 +253,6 @@ struct VADriverVTable
254253 VAImageID image,
255254 int src_x,
256255 int src_y,
257- unsigned int width,
258- unsigned int height,
259- int dest_x,
260- int dest_y
261- );
262-
263- VAStatus (*vaPutImage2) (
264- VADriverContextP ctx,
265- VASurfaceID surface,
266- VAImageID image,
267- int src_x,
268- int src_y,
269256 unsigned int src_width,
270257 unsigned int src_height,
271258 int dest_x,
@@ -319,24 +306,6 @@ struct VADriverVTable
319306 int num_surfaces,
320307 short src_x, /* upper left offset in subpicture */
321308 short src_y,
322- short dest_x, /* upper left offset in surface */
323- short dest_y,
324- unsigned short width,
325- unsigned short height,
326- /*
327- * whether to enable chroma-keying or global-alpha
328- * see VA_SUBPICTURE_XXX values
329- */
330- unsigned int flags
331- );
332-
333- VAStatus (*vaAssociateSubpicture2) (
334- VADriverContextP ctx,
335- VASubpictureID subpicture,
336- VASurfaceID *target_surfaces,
337- int num_surfaces,
338- short src_x, /* upper left offset in subpicture */
339- short src_y,
340309 unsigned short src_width,
341310 unsigned short src_height,
342311 short dest_x, /* upper left offset in surface */
--- a/src/x11/va_x11.c
+++ b/src/x11/va_x11.c
@@ -205,27 +205,6 @@ static VAStatus va_DisplayContextGetDriverName (
205205 return vaStatus;
206206 }
207207
208-int vaDisplayIsValid(VADisplay dpy)
209-{
210- VADisplayContextP tmp=NULL;
211- VADisplayContextP pDisplayContext = pDisplayContexts;
212-
213- while (pDisplayContext)
214- {
215- if (pDisplayContext == (VADisplayContextP)dpy)
216- {
217- tmp = (VADisplay)pDisplayContext;
218- break;
219- }
220- pDisplayContext = pDisplayContext->pNext;
221- }
222-
223- if (!tmp)
224- return 0;
225-
226- return tmp->vaIsValid(pDisplayContext);
227-}
228-
229208
230209 VADisplay vaGetDisplay (
231210 Display *native_dpy /* implementation specific */
--- a/test/test_12.c
+++ b/test/test_12.c
@@ -222,7 +222,7 @@ void test()
222222 va_status = vaEndPicture(va_dpy,vaContext);
223223 ASSERT( VA_STATUS_SUCCESS == va_status );
224224
225- va_status = vaSyncSurface(va_dpy, vaContext, vaSurface);
225+ va_status = vaSyncSurface(va_dpy, vaSurface);
226226 ASSERT( VA_STATUS_SUCCESS == va_status );
227227
228228 win = XCreateSimpleWindow(dpy, RootWindow(dpy, 0), 0, 0,