[Mesa-dev] [PATCH 07/11] st/xvmc: respect caps when creating video buffers

Christian König deathsimple at vodafone.de
Wed Feb 1 15:20:00 PST 2012


Signed-off-by: Christian König <deathsimple at vodafone.de>
---
 src/gallium/state_trackers/xorg/xvmc/surface.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/src/gallium/state_trackers/xorg/xvmc/surface.c b/src/gallium/state_trackers/xorg/xvmc/surface.c
index f1c3271..024612e 100644
--- a/src/gallium/state_trackers/xorg/xvmc/surface.c
+++ b/src/gallium/state_trackers/xorg/xvmc/surface.c
@@ -184,6 +184,12 @@ Status XvMCCreateSurface(Display *dpy, XvMCContext *context, XvMCSurface *surfac
    tmpl.chroma_format = context_priv->decoder->chroma_format;
    tmpl.width = context_priv->decoder->width;
    tmpl.height = context_priv->decoder->height;
+   tmpl.interlaced = pipe->screen->get_video_param
+   (
+      pipe->screen,
+      PIPE_VIDEO_PROFILE_MPEG2_MAIN,
+      PIPE_VIDEO_CAP_PREFERS_INTERLACED
+   );
 
    surface_priv->video_buffer = pipe->create_video_buffer(pipe, &tmpl);
    surface_priv->context = context;
-- 
1.7.5.4



More information about the mesa-dev mailing list