Commit 442beb1d authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Clear resources that we aren't recording in stateblock_init().

parent 61abc0a5
......@@ -1674,6 +1674,13 @@ HRESULT stateblock_init(IWineD3DStateBlockImpl *stateblock, IWineD3DDeviceImpl *
{
stateblock->streamSource[i] = NULL;
}
for (i = 0; i < MAX_COMBINED_SAMPLERS; ++i)
{
stateblock->textures[i] = NULL;
}
stateblock->vertexDecl = NULL;
stateblock->pIndexData = NULL;
stateblock->vertexShader = NULL;
}
......@@ -1700,8 +1707,14 @@ HRESULT stateblock_init(IWineD3DStateBlockImpl *stateblock, IWineD3DDeviceImpl *
if (stateblock->streamSource[i]) IWineD3DBuffer_AddRef(stateblock->streamSource[i]);
}
for (i = 0; i < MAX_COMBINED_SAMPLERS; ++i)
{
stateblock->textures[i] = NULL;
}
if (stateblock->vertexShader) IWineD3DVertexShader_AddRef(stateblock->vertexShader);
stateblock->vertexDecl = NULL;
stateblock->pIndexData = NULL;
stateblock->pixelShader = NULL;
}
......
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