Stefan Dösinger : wined3d: Catch nop pixel shader changes.
Alexandre Julliard
julliard at wine.codeweavers.com
Thu Jan 4 04:45:08 CST 2007
Module: wine
Branch: master
Commit: 4e0f7ccd7d63d65fed899f0fea86ab633e34e7bf
URL: http://source.winehq.org/git/wine.git/?a=commit;h=4e0f7ccd7d63d65fed899f0fea86ab633e34e7bf
Author: Stefan Dösinger <stefan at codeweavers.com>
Date: Thu Jan 4 00:07:45 2007 +0100
wined3d: Catch nop pixel shader changes.
---
dlls/wined3d/device.c | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index 6a51771..f53f339 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -3260,6 +3260,11 @@ static HRESULT WINAPI IWineD3DDeviceImpl
if (This->isRecordingState) {
TRACE("Recording... not performing anything\n");
+ return WINED3D_OK;
+ } else if(oldShader == pShader) {
+ /* Checked here to allow proper stateblock recording */
+ TRACE("App is setting the old shader over, nothing to do\n");
+ return WINED3D_OK;
}
if (NULL != pShader) {
@@ -5832,7 +5837,7 @@ static void device_reapply_stateblock(IW
/* Temporaryily mark all render states dirty to force reapplication
* until the context management for is integrated with the state management
- * The same for the pixel shader, vertex declaration
+ * The same for the pixel shader, vertex declaration and vertex shader
* Sampler states and texture stage states are marked
* dirty my StateBlock::Apply already.
*/
@@ -5841,6 +5846,7 @@ static void device_reapply_stateblock(IW
}
IWineD3DDeviceImpl_MarkStateDirty(This, STATE_PIXELSHADER);
IWineD3DDeviceImpl_MarkStateDirty(This, STATE_VDECL);
+ IWineD3DDeviceImpl_MarkStateDirty(This, STATE_VSHADER);
/* Restore recording */
This->isRecordingState = oldRecording;
More information about the wine-cvs
mailing list