Henri Verbeet : wined3d: Don't die if a vertex shader has samplers.
Alexandre Julliard
julliard at winehq.org
Thu Apr 16 14:34:47 CDT 2009
Module: wine
Branch: master
Commit: a7e2c2d70ce8cb1d537248c73f75ea21d41566f3
URL: http://source.winehq.org/git/wine.git/?a=commit;h=a7e2c2d70ce8cb1d537248c73f75ea21d41566f3
Author: Henri Verbeet <hverbeet at codeweavers.com>
Date: Wed Apr 15 10:06:28 2009 +0200
wined3d: Don't die if a vertex shader has samplers.
This fixes a regression introduced by 38239be58ca709ca107752ca7d3fee0763832725.
---
dlls/wined3d/glsl_shader.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c
index 61c5701..0a9240d 100644
--- a/dlls/wined3d/glsl_shader.c
+++ b/dlls/wined3d/glsl_shader.c
@@ -825,7 +825,8 @@ static void shader_generate_glsl_declarations(IWineD3DBaseShader *iface, const s
shader_addline(buffer, "uniform sampler2D %csampler%u;\n", prefix, i);
}
- if(ps_args->np2_fixup & (1 << i)) {
+ if (pshader && ps_args->np2_fixup & (1 << i))
+ {
/* NP2/RECT textures in OpenGL use texcoords in the range [0,width]x[0,height]
* while D3D has them in the (normalized) [0,1]x[0,1] range.
* samplerNP2Fixup stores texture dimensions and is updated through
More information about the wine-cvs
mailing list