Commit fc60083e authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Handle the destination modifier shift in the frontend rather than the backend.

parent 7448a092
......@@ -1000,10 +1000,10 @@ static void shader_hw_map2gl(const struct wined3d_shader_instruction *ins)
partialprecision = mask & WINED3DSPDM_PARTIALPRECISION;
mask &= ~(WINED3DSPDM_MSAMPCENTROID | WINED3DSPDM_PARTIALPRECISION | WINED3DSPDM_SATURATE);
if (mask)
FIXME("Unrecognized modifier(%#x)\n", mask >> WINED3DSP_DSTMOD_SHIFT);
FIXME("Unrecognized modifier(%#x)\n", mask);
if (centroid)
FIXME("Unhandled modifier(%#x)\n", mask >> WINED3DSP_DSTMOD_SHIFT);
FIXME("Unhandled modifier(%#x)\n", mask);
}
shift = dst->shift;
modifier = (saturate && !shift) ? "_SAT" : "";
......
......@@ -234,7 +234,7 @@ static void shader_parse_dst_param(DWORD param, const struct wined3d_shader_src_
| ((param & WINED3DSP_REGTYPE_MASK2) >> WINED3DSP_REGTYPE_SHIFT2);
dst->register_idx = param & WINED3DSP_REGNUM_MASK;
dst->write_mask = param & WINED3DSP_WRITEMASK_ALL;
dst->modifiers = param & WINED3DSP_DSTMOD_MASK;
dst->modifiers = (param & WINED3DSP_DSTMOD_MASK) >> WINED3DSP_DSTMOD_SHIFT;
dst->shift = (param & WINED3DSP_DSTSHIFT_MASK) >> WINED3DSP_DSTSHIFT_SHIFT;
dst->rel_addr = rel_addr;
}
......@@ -966,7 +966,7 @@ static void shader_dump_ins_modifiers(const DWORD output)
mmask &= ~(WINED3DSPDM_SATURATE | WINED3DSPDM_PARTIALPRECISION | WINED3DSPDM_MSAMPCENTROID);
if (mmask)
FIXME("_unrecognized_modifier(%#x)", mmask >> WINED3DSP_DSTMOD_SHIFT);
FIXME("_unrecognized_modifier(%#x)", mmask);
}
void shader_trace_init(const DWORD *pFunction, const SHADER_OPCODE *opcode_table)
......
......@@ -136,10 +136,10 @@ typedef enum _WINED3DSHADER_PARAM_SRCMOD_TYPE {
#define WINED3DSP_DSTMOD_MASK (0xF << WINED3DSP_DSTMOD_SHIFT)
typedef enum _WINED3DSHADER_PARAM_DSTMOD_TYPE {
WINED3DSPDM_NONE = 0 << WINED3DSP_DSTMOD_SHIFT,
WINED3DSPDM_SATURATE = 1 << WINED3DSP_DSTMOD_SHIFT,
WINED3DSPDM_PARTIALPRECISION = 2 << WINED3DSP_DSTMOD_SHIFT,
WINED3DSPDM_MSAMPCENTROID = 4 << WINED3DSP_DSTMOD_SHIFT,
WINED3DSPDM_NONE = 0,
WINED3DSPDM_SATURATE = 1,
WINED3DSPDM_PARTIALPRECISION = 2,
WINED3DSPDM_MSAMPCENTROID = 4,
WINED3DSPDM_FORCE_DWORD = 0x7FFFFFFF
} WINED3DSHADER_PARAM_DSTMOD_TYPE;
......
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