Mercurial > mplayer.hg
comparison libvo/vo_gl2.c @ 16594:7b30ec73e83e
debugging/testing helpers: allow forcing a certain width/height for textures
author | reimar |
---|---|
date | Sun, 25 Sep 2005 16:33:03 +0000 |
parents | 3ffa9bee23d4 |
children | b36b5bb95a9b |
comparison
equal
deleted
inserted
replaced
16593:1c13fb2ba5a9 | 16594:7b30ec73e83e |
---|---|
27 | 27 |
28 #undef TEXTUREFORMAT_ALWAYS | 28 #undef TEXTUREFORMAT_ALWAYS |
29 #ifdef SYS_DARWIN | 29 #ifdef SYS_DARWIN |
30 #define TEXTUREFORMAT_ALWAYS GL_RGBA8 | 30 #define TEXTUREFORMAT_ALWAYS GL_RGBA8 |
31 #endif | 31 #endif |
32 | |
33 //! force texture height, useful for debugging | |
34 #define TEXTURE_HEIGHT 128 | |
35 #undef TEXTURE_HEIGHT | |
36 //! force texture width, useful for debugging | |
37 #define TEXTURE_WIDTH 128 | |
38 #undef TEXTURE_WIDTH | |
32 | 39 |
33 static vo_info_t info = | 40 static vo_info_t info = |
34 { | 41 { |
35 "X11 (OpenGL) - multiple textures version", | 42 "X11 (OpenGL) - multiple textures version", |
36 "gl2", | 43 "gl2", |
195 return -1; | 202 return -1; |
196 } | 203 } |
197 } | 204 } |
198 } | 205 } |
199 while (format != gl_internal_format && texture_width > 1 && texture_height > 1); | 206 while (format != gl_internal_format && texture_width > 1 && texture_height > 1); |
207 #ifdef TEXTURE_WIDTH | |
208 texture_width = TEXTURE_WIDTH; | |
209 #endif | |
210 #ifdef TEXTURE_HEIGHT | |
211 texture_height = TEXTURE_HEIGHT; | |
212 #endif | |
200 | 213 |
201 texnumx = image_width / texture_width; | 214 texnumx = image_width / texture_width; |
202 if ((image_width % texture_width) > 0) | 215 if ((image_width % texture_width) > 0) |
203 texnumx++; | 216 texnumx++; |
204 | 217 |