Commit b29c7da5 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

ddraw: Track some more render states in the primary stateblock.

parent cb6f4882
......@@ -3555,6 +3555,7 @@ static void setup_lighting(const struct d3d_device *device, DWORD fvf, DWORD fla
if (!device->material || !(fvf & D3DFVF_NORMAL) || (flags & D3DDP_DONOTLIGHT))
enable = FALSE;
wined3d_stateblock_set_render_state(device->state, WINED3D_RS_LIGHTING, enable);
wined3d_device_set_render_state(device->wined3d_device, WINED3D_RS_LIGHTING, enable);
}
......@@ -7033,11 +7034,18 @@ static HRESULT d3d_device_init(struct d3d_device *device, struct ddraw *ddraw,
wined3d_device_set_render_state(ddraw->wined3d_device, WINED3D_RS_ZENABLE,
d3d_device_update_depth_stencil(device));
if (version == 1) /* Color keying is initially enabled for version 1 devices. */
{
wined3d_stateblock_set_render_state(ddraw->state, WINED3D_RS_COLORKEYENABLE, TRUE);
wined3d_device_set_render_state(ddraw->wined3d_device, WINED3D_RS_COLORKEYENABLE, TRUE);
}
else if (version == 2)
{
wined3d_stateblock_set_render_state(ddraw->state, WINED3D_RS_SPECULARENABLE, TRUE);
wined3d_device_set_render_state(ddraw->wined3d_device, WINED3D_RS_SPECULARENABLE, TRUE);
}
if (version < 7)
{
wined3d_stateblock_set_render_state(ddraw->state, WINED3D_RS_NORMALIZENORMALS, TRUE);
wined3d_device_set_render_state(ddraw->wined3d_device, WINED3D_RS_NORMALIZENORMALS, TRUE);
IDirect3DDevice3_SetRenderState(&device->IDirect3DDevice3_iface,
D3DRENDERSTATE_TEXTUREMAPBLEND, D3DTBLEND_MODULATE);
......
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