Commit 6192f77d authored by Christoph Frick's avatar Christoph Frick Committed by Alexandre Julliard

wined3d: Clamp the light exponent at 128.

parent d51594d0
......@@ -2755,6 +2755,9 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetLight(IWineD3DDevice *iface, DWORD I
}
if (rho < 0.0001) rho = 0.0001f;
object->exponent = -0.3/log(cos(rho/2));
if (object->exponent > 128.0) {
object->exponent = 128.0;
}
object->cutoff = pLight->Phi*90/M_PI;
/* FIXME: Range */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment