mirror of
https://gitlab.winehq.org/wine/wine.git
synced 2024-11-19 17:06:04 -07:00
wined3d: Do not clamp fog in the VS.
NVidia and WARP clamp before interpolation in the oFog case; AMD clamps only after interpolation (which we also do). On the other hand, test_fog() proves that clamping should not be done before interpolation in the FFP case, for any driver. In order to emulate an FFP vertex shader with a real compiled shader, we need to avoid clamping before interpolation, choosing the AMD behaviour here.
This commit is contained in:
parent
a5de8d85d3
commit
b02b73673b
Notes:
Alexandre Julliard
2024-11-13 22:30:11 +01:00
Approved-by: Jan Sikorski (@jsikorski) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/wine/merge_requests/6756
1 changed files with 1 additions and 1 deletions
|
@ -7366,7 +7366,7 @@ static GLuint shader_glsl_generate_vs3_rasterizer_input_setup(struct shader_glsl
|
|||
}
|
||||
else if (shader_match_semantic(semantic_name, WINED3D_DECL_USAGE_FOG))
|
||||
{
|
||||
shader_addline(buffer, "%s = clamp(outputs[%u].%c, 0.0, 1.0);\n",
|
||||
shader_addline(buffer, "%s = outputs[%u].%c;\n",
|
||||
legacy_syntax ? "gl_FogFragCoord" : "ffp_varying_fogcoord",
|
||||
output->register_idx, reg_mask[1]);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue