st/vdpau: add xine workaround
authorChristian König <deathsimple@vodafone.de>
Mon, 5 Mar 2012 15:44:42 +0000 (16:44 +0100)
committerChristian König <deathsimple@vodafone.de>
Fri, 9 Mar 2012 11:44:20 +0000 (12:44 +0100)
For reasons I don't understand xine tries to set
the surface format by using a zero pitch.

Signed-off-by: Christian König <deathsimple@vodafone.de>
src/gallium/state_trackers/vdpau/surface.c

index 916260225011eb02af7ee503f918e465c51e8423..c829c1ff7dec4172dd8d36eb26102ff7bd3be880 100644 (file)
@@ -292,7 +292,7 @@ vlVdpVideoSurfacePutBitsYCbCr(VdpVideoSurface surface,
 
    for (i = 0; i < 3; ++i) {
       struct pipe_sampler_view *sv = sampler_views[i];
-      if (!sv) continue;
+      if (!sv || !source_pitches[i]) continue;
 
       for (j = 0; j < sv->texture->depth0; ++j) {
          struct pipe_box dst_box = {