wined3d: Use application provided fog range when fog is enabled.

This commit is contained in:
Vitaliy Margolen 2007-02-25 18:03:00 -07:00 committed by Alexandre Julliard
parent bea5199b6f
commit 51ee7f4978
1 changed files with 4 additions and 2 deletions

View File

@ -678,8 +678,10 @@ static void state_fog(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3DCo
((IWineD3DVertexShaderImpl *)stateblock->vertexShader)->usesFog) {
glFogi(GL_FOG_MODE, GL_LINEAR);
checkGLcall("glFogi(GL_FOG_MODE, GL_LINEAR)");
fogstart = 1.0;
fogend = 0.0;
if (stateblock->renderState[WINED3DRS_FOGTABLEMODE] == WINED3DFOG_NONE) {
fogstart = 1.0;
fogend = 0.0;
}
context->last_was_foggy_shader = TRUE;
}
/* DX 7 sdk: "If both render states(vertex and table fog) are set to valid modes,