aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/vl
diff options
context:
space:
mode:
authorAndy Furniss <[email protected]>2013-07-25 00:40:11 +0100
committerChristian König <[email protected]>2013-08-19 18:31:26 +0200
commit3448b66dac521fb16ccaa7cdf3427343a6e355a2 (patch)
treeda3ca63cf7f532d5a4f97978cce29c868b68d7f2 /src/gallium/auxiliary/vl
parentb1d05eeb1f14e06ba122857927eb4661621df8f6 (diff)
vdpau/vl 422 chroma width/height mix up
I was looking into some minor 422 issues/discrepencies I noticed long ago using vdpau on my rv790. I noticed that there is code that is halving height rather than width - 422 is full height AFAIK. Making the changes below doesn't actually make any noticable difference to what I was looking into. Maybe there are more but here's three I've found so far Reviewed-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium/auxiliary/vl')
-rw-r--r--src/gallium/auxiliary/vl/vl_mpeg12_decoder.c4
-rw-r--r--src/gallium/auxiliary/vl/vl_video_buffer.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/auxiliary/vl/vl_mpeg12_decoder.c b/src/gallium/auxiliary/vl/vl_mpeg12_decoder.c
index b60b22fc265..5782f620e61 100644
--- a/src/gallium/auxiliary/vl/vl_mpeg12_decoder.c
+++ b/src/gallium/auxiliary/vl/vl_mpeg12_decoder.c
@@ -1053,8 +1053,8 @@ vl_create_mpeg12_decoder(struct pipe_context *context,
dec->chroma_height = dec->base.height / 2;
dec->num_blocks = dec->num_blocks * 2;
} else if (dec->base.chroma_format == PIPE_VIDEO_CHROMA_FORMAT_422) {
- dec->chroma_width = dec->base.width;
- dec->chroma_height = dec->base.height / 2;
+ dec->chroma_width = dec->base.width / 2;
+ dec->chroma_height = dec->base.height;
dec->num_blocks = dec->num_blocks * 2 + dec->num_blocks;
} else {
dec->chroma_width = dec->base.width;
diff --git a/src/gallium/auxiliary/vl/vl_video_buffer.c b/src/gallium/auxiliary/vl/vl_video_buffer.c
index f0ba3891eb6..3b599fcd12f 100644
--- a/src/gallium/auxiliary/vl/vl_video_buffer.c
+++ b/src/gallium/auxiliary/vl/vl_video_buffer.c
@@ -240,7 +240,7 @@ vl_video_buffer_template(struct pipe_resource *templ,
templ->width0 /= 2;
templ->height0 /= 2;
} else if (tmpl->chroma_format == PIPE_VIDEO_CHROMA_FORMAT_422) {
- templ->height0 /= 2;
+ templ->width0 /= 2;
}
}
}