Commit 2861ce93 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

d3d10/effect: Add support for 'ceil' instruction.

parent 2043ffa0
......@@ -343,6 +343,17 @@ static void pres_ftob(float **args, unsigned int n, const struct preshader_instr
}
}
/* Only first source component is used. */
static void pres_ceil(float **args, unsigned int n, const struct preshader_instr *instr)
{
float value = ceilf(args[0][0]);
float *retval = args[1];
unsigned int i;
for (i = 0; i < instr->comp_count; ++i)
retval[i] = value;
}
static void pres_min(float **args, unsigned int n, const struct preshader_instr *instr)
{
float *retval = args[2];
......@@ -622,6 +633,7 @@ static const struct preshader_op_info preshader_ops[] =
{ 0x131, "utof", pres_utof },
{ 0x133, "ftou", pres_ftou },
{ 0x137, "ftob", pres_ftob },
{ 0x13a, "ceil", pres_ceil },
{ 0x200, "min", pres_min },
{ 0x201, "max", pres_max },
{ 0x204, "add", pres_add },
......
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