summaryrefslogtreecommitdiffstats
path: root/libvo
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2008-12-06 12:13:14 +0000
committerreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2008-12-06 12:13:14 +0000
commitd761fd207a02e43bc205c2819e3fb184f419527f (patch)
treee04a47271b8193677bb197bba2f2a3913d5472b9 /libvo
parente70a7dde5ef4425560fbe3424d3f46e68e3a8854 (diff)
downloadmpv-d761fd207a02e43bc205c2819e3fb184f419527f.tar.bz2
mpv-d761fd207a02e43bc205c2819e3fb184f419527f.tar.xz
ati_hack only makes sense when PBOs are used, not with mesa_buffer.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@28108 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/vo_gl.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libvo/vo_gl.c b/libvo/vo_gl.c
index c1c1d7357b..19e3459637 100644
--- a/libvo/vo_gl.c
+++ b/libvo/vo_gl.c
@@ -177,8 +177,8 @@ static void texSize(int w, int h, int *texw, int *texh) {
while (*texh < h)
*texh *= 2;
}
- if (ati_hack) *texw = (*texw + 511) & ~511;
if (mesa_buffer) *texw = (*texw + 63) & ~63;
+ else if (ati_hack) *texw = (*texw + 511) & ~511;
}
//! maximum size of custom fragment program
@@ -699,11 +699,11 @@ static uint32_t get_image(mp_image_t *mpi) {
return VO_FALSE;
}
if (mpi->flags & MP_IMGFLAG_READABLE) return VO_FALSE;
- if (ati_hack) {
+ if (mesa_buffer) mpi->width = texture_width;
+ else if (ati_hack) {
mpi->width = texture_width;
mpi->height = texture_height;
}
- if (mesa_buffer) mpi->width = texture_width;
mpi->stride[0] = mpi->width * mpi->bpp / 8;
needed_size = mpi->stride[0] * mpi->height;
if (mesa_buffer) {
@@ -746,7 +746,7 @@ static uint32_t get_image(mp_image_t *mpi) {
mpi->stride[1] = mpi->width >> 1;
mpi->planes[2] = mpi->planes[1] + mpi->stride[1] * (mpi->height >> 1);
mpi->stride[2] = mpi->width >> 1;
- if (ati_hack) {
+ if (ati_hack && !mesa_buffer) {
mpi->flags &= ~MP_IMGFLAG_COMMON_PLANE;
if (!gl_buffer_uv[0]) GenBuffers(2, gl_buffer_uv);
if (mpi->stride[1] * mpi->height > gl_buffersize_uv) {