wined3d: Support ABS and ABSNEG in ARB.

This commit is contained in:
Stefan Dösinger 2009-05-21 11:58:20 +02:00 committed by Alexandre Julliard
parent bdb54fdaf2
commit 60f20a2f39
1 changed files with 8 additions and 0 deletions

View File

@ -850,6 +850,14 @@ static void shader_arb_get_src_param(const struct wined3d_shader_instruction *in
shader_addline(buffer, "RCP T%c, %s.w;\n", 'A' + tmpreg, regstr);
shader_addline(buffer, "MUL T%c, %s, T%c;\n", 'A' + tmpreg, regstr, 'A' + tmpreg);
break;
case WINED3DSPSM_ABS:
shader_addline(buffer, "ABS T%c, %s;\n", 'A' + tmpreg, regstr);
break;
case WINED3DSPSM_ABSNEG:
shader_addline(buffer, "ABS T%c, %s;\n", 'A' + tmpreg, regstr);
sprintf(outregstr, "-T%c%s", 'A' + tmpreg, swzstr);
insert_line = 0;
break;
default:
sprintf(outregstr, "%s%s", regstr, swzstr);
insert_line = 0;