summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/vdpau/device.c
diff options
context:
space:
mode:
authorChristian König <[email protected]>2011-04-06 20:38:16 +0200
committerChristian König <[email protected]>2011-04-06 20:38:16 +0200
commit2c21d28e8315ff65cb6f47fda46cbd65d67fb4e7 (patch)
tree98caf78fa2b76fdbd6d057658e559a2fb108da42 /src/gallium/state_trackers/vdpau/device.c
parent05a2247a945db21ec5fdb39f6270c5cb2ab6bb6f (diff)
vdpau: implement vlVdpVideoSurfacePutBitsYCbCr
Diffstat (limited to 'src/gallium/state_trackers/vdpau/device.c')
-rw-r--r--src/gallium/state_trackers/vdpau/device.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/vdpau/device.c b/src/gallium/state_trackers/vdpau/device.c
index d3314d0d4bf..7906757ec1b 100644
--- a/src/gallium/state_trackers/vdpau/device.c
+++ b/src/gallium/state_trackers/vdpau/device.c
@@ -61,6 +61,12 @@ vdp_imp_device_create_x11(Display *display, int screen, VdpDevice *device,
goto no_vscreen;
}
+ dev->context = vl_video_create(dev->vscreen);
+ if (!dev->context) {
+ ret = VDP_STATUS_RESOURCES;
+ goto no_context;
+ }
+
*device = vlAddDataHTAB(dev);
if (*device == 0) {
ret = VDP_STATUS_ERROR;
@@ -74,6 +80,8 @@ vdp_imp_device_create_x11(Display *display, int screen, VdpDevice *device,
no_handle:
/* Destroy vscreen */
+no_context:
+ vl_screen_destroy(dev->vscreen);
no_vscreen:
FREE(dev);
no_dev: