Henri Verbeet : wined3d: Recognize the SM4 sqrt opcode.
Alexandre Julliard
julliard at winehq.org
Wed Oct 20 13:24:39 CDT 2010
Module: wine
Branch: master
Commit: d508a855c16fa6bd24c89c6bfcd6d5c128f22d72
URL: http://source.winehq.org/git/wine.git/?a=commit;h=d508a855c16fa6bd24c89c6bfcd6d5c128f22d72
Author: Henri Verbeet <hverbeet at codeweavers.com>
Date: Wed Oct 20 12:12:27 2010 +0200
wined3d: Recognize the SM4 sqrt opcode.
---
dlls/wined3d/arb_program_shader.c | 1 +
dlls/wined3d/glsl_shader.c | 1 +
dlls/wined3d/shader.c | 1 +
dlls/wined3d/shader_sm4.c | 2 ++
dlls/wined3d/wined3d_private.h | 1 +
5 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader.c
index 2f70a57..3678f44 100644
--- a/dlls/wined3d/arb_program_shader.c
+++ b/dlls/wined3d/arb_program_shader.c
@@ -5007,6 +5007,7 @@ static const SHADER_HANDLER shader_arb_instruction_handler_table[WINED3DSIH_TABL
/* WINED3DSIH_SGN */ shader_hw_sgn,
/* WINED3DSIH_SINCOS */ shader_hw_sincos,
/* WINED3DSIH_SLT */ shader_hw_map2gl,
+ /* WINED3DSIH_SQRT */ NULL,
/* WINED3DSIH_SUB */ shader_hw_map2gl,
/* WINED3DSIH_TEX */ pshader_hw_tex,
/* WINED3DSIH_TEXBEM */ pshader_hw_texbem,
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c
index fb7d02e..85b1a28 100644
--- a/dlls/wined3d/glsl_shader.c
+++ b/dlls/wined3d/glsl_shader.c
@@ -5065,6 +5065,7 @@ static const SHADER_HANDLER shader_glsl_instruction_handler_table[WINED3DSIH_TAB
/* WINED3DSIH_SGN */ shader_glsl_sgn,
/* WINED3DSIH_SINCOS */ shader_glsl_sincos,
/* WINED3DSIH_SLT */ shader_glsl_compare,
+ /* WINED3DSIH_SQRT */ NULL,
/* WINED3DSIH_SUB */ shader_glsl_arith,
/* WINED3DSIH_TEX */ shader_glsl_tex,
/* WINED3DSIH_TEXBEM */ shader_glsl_texbem,
diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c
index e3451a5..77ffacb 100644
--- a/dlls/wined3d/shader.c
+++ b/dlls/wined3d/shader.c
@@ -111,6 +111,7 @@ static const char * const shader_opcode_names[] =
/* WINED3DSIH_SGN */ "sgn",
/* WINED3DSIH_SINCOS */ "sincos",
/* WINED3DSIH_SLT */ "slt",
+ /* WINED3DSIH_SQRT */ "sqrt",
/* WINED3DSIH_SUB */ "sub",
/* WINED3DSIH_TEX */ "texld",
/* WINED3DSIH_TEXBEM */ "texbem",
diff --git a/dlls/wined3d/shader_sm4.c b/dlls/wined3d/shader_sm4.c
index ef7af43..d0b36c6 100644
--- a/dlls/wined3d/shader_sm4.c
+++ b/dlls/wined3d/shader_sm4.c
@@ -87,6 +87,7 @@ enum wined3d_sm4_opcode
WINED3D_SM4_OP_SAMPLE = 0x45,
WINED3D_SM4_OP_SAMPLE_LOD = 0x48,
WINED3D_SM4_OP_SAMPLE_GRAD = 0x49,
+ WINED3D_SM4_OP_SQRT = 0x4b,
WINED3D_SM4_OP_SINCOS = 0x4d,
WINED3D_SM4_OP_UTOF = 0x56,
};
@@ -167,6 +168,7 @@ static const struct wined3d_sm4_opcode_info opcode_table[] =
{WINED3D_SM4_OP_SAMPLE, WINED3DSIH_SAMPLE, 1, 3},
{WINED3D_SM4_OP_SAMPLE_LOD, WINED3DSIH_SAMPLE_LOD, 1, 4},
{WINED3D_SM4_OP_SAMPLE_GRAD,WINED3DSIH_SAMPLE_GRAD, 1, 5},
+ {WINED3D_SM4_OP_SQRT, WINED3DSIH_SQRT, 1, 1},
{WINED3D_SM4_OP_SINCOS, WINED3DSIH_SINCOS, 2, 1},
{WINED3D_SM4_OP_UTOF, WINED3DSIH_UTOF, 1, 1},
};
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
index 77a512a..bc77f62 100644
--- a/dlls/wined3d/wined3d_private.h
+++ b/dlls/wined3d/wined3d_private.h
@@ -480,6 +480,7 @@ enum WINED3D_SHADER_INSTRUCTION_HANDLER
WINED3DSIH_SGN,
WINED3DSIH_SINCOS,
WINED3DSIH_SLT,
+ WINED3DSIH_SQRT,
WINED3DSIH_SUB,
WINED3DSIH_TEX,
WINED3DSIH_TEXBEM,
More information about the wine-cvs
mailing list