Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2011-10-28 20:57:06 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2011-10-28 20:57:06 +0400
commited77c356fc1c323cef306fef2e7af03fd67a6871 (patch)
treebf7c31d131d6fc65030c3bcf9940469c8450813e /source/blender/gpu/intern/gpu_material.c
parent7627a742ab6e630522186b04a71fa40533d87db2 (diff)
Fix: OpenGL renders on graphics cards which do not support non-power-of-two
textures were stretched and the wrong size.
Diffstat (limited to 'source/blender/gpu/intern/gpu_material.c')
-rw-r--r--source/blender/gpu/intern/gpu_material.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c
index d0f834977c8..26c08f6cae5 100644
--- a/source/blender/gpu/intern/gpu_material.c
+++ b/source/blender/gpu/intern/gpu_material.c
@@ -1661,7 +1661,8 @@ void GPU_lamp_shadow_buffer_bind(GPULamp *lamp, float viewmat[][4], int *winsize
/* opengl */
glDisable(GL_SCISSOR_TEST);
- GPU_framebuffer_texture_bind(lamp->fb, lamp->tex);
+ GPU_framebuffer_texture_bind(lamp->fb, lamp->tex,
+ GPU_texture_opengl_width(lamp->tex), GPU_texture_opengl_height(lamp->tex));
/* set matrices */
copy_m4_m4(viewmat, lamp->viewmat);