st/xorg: enable yv12 for xv
authorZack Rusin <zackr@vmware.com>
Wed, 18 Nov 2009 17:06:32 +0000 (12:06 -0500)
committerZack Rusin <zackr@vmware.com>
Thu, 10 Dec 2009 18:04:05 +0000 (13:04 -0500)
src/gallium/state_trackers/xorg/xorg_xv.c

index b3315dccad8c43c23708dff85141dae53aaf6914..fdc1cdb82eec0a447a26ad5451a0291104cea988 100644 (file)
@@ -73,10 +73,11 @@ static XF86VideoEncodingRec DummyEncoding[1] = {
    }
 };
 
-#define NUM_IMAGES 2
+#define NUM_IMAGES 3
 static XF86ImageRec Images[NUM_IMAGES] = {
    XVIMAGE_UYVY,
    XVIMAGE_YUY2,
+   XVIMAGE_YV12,
 };
 
 struct xorg_xv_port_priv {
@@ -532,6 +533,7 @@ put_image(ScrnInfoPtr pScrn,
    switch (id) {
    case FOURCC_UYVY:
    case FOURCC_YUY2:
+   case FOURCC_YV12:
    default:
       srcPitch = width << 1;
       break;
@@ -580,6 +582,7 @@ query_image_attributes(ScrnInfoPtr pScrn,
    switch (id) {
    case FOURCC_UYVY:
    case FOURCC_YUY2:
+   case FOURCC_YV12:
    default:
       size = *w << 1;
       if (pitches)