[PATCH 02/10] wined3d: Handle SM5 derivative instructions in shader_get_registers_used().

Józef Kucia jkucia at codeweavers.com
Wed Jul 27 16:33:40 CDT 2016


Signed-off-by: Józef Kucia <jkucia at codeweavers.com>
---
 dlls/wined3d/shader.c | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c
index 5192b18..f1940c6 100644
--- a/dlls/wined3d/shader.c
+++ b/dlls/wined3d/shader.c
@@ -1217,8 +1217,18 @@ static HRESULT shader_get_registers_used(struct wined3d_shader *shader, const st
             }
 
             if (ins.handler_idx == WINED3DSIH_NRM) reg_maps->usesnrm = 1;
-            else if (ins.handler_idx == WINED3DSIH_DSY) reg_maps->usesdsy = 1;
-            else if (ins.handler_idx == WINED3DSIH_DSX) reg_maps->usesdsx = 1;
+            else if (ins.handler_idx == WINED3DSIH_DSY
+                    || ins.handler_idx == WINED3DSIH_DSY_COARSE
+                    || ins.handler_idx == WINED3DSIH_DSY_FINE)
+            {
+                reg_maps->usesdsy = 1;
+            }
+            else if (ins.handler_idx == WINED3DSIH_DSX
+                    || ins.handler_idx == WINED3DSIH_DSX_COARSE
+                    || ins.handler_idx == WINED3DSIH_DSX_FINE)
+            {
+                reg_maps->usesdsx = 1;
+            }
             else if (ins.handler_idx == WINED3DSIH_TEXLDD) reg_maps->usestexldd = 1;
             else if (ins.handler_idx == WINED3DSIH_TEXLDL) reg_maps->usestexldl = 1;
             else if (ins.handler_idx == WINED3DSIH_MOVA) reg_maps->usesmova = 1;
-- 
2.7.3




More information about the wine-patches mailing list