Skip to content

Commit

Permalink
Implemented POW in GLSL profile.
Browse files Browse the repository at this point in the history
--HG--
branch : trunk
  • Loading branch information
icculus committed Apr 6, 2008
1 parent 32cbd53 commit 7e7d4e4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion mojoshader.c
Expand Up @@ -2336,7 +2336,10 @@ static void emit_GLSL_DCL(Context *ctx)

static void emit_GLSL_POW(Context *ctx)
{
fail(ctx, "unimplemented."); // !!! FIXME
const char *src0 = make_GLSL_sourcearg_string(ctx, 0);
const char *src1 = make_GLSL_sourcearg_string(ctx, 1);
const char *code = make_GLSL_destarg_assign(ctx, 0, "pow(abs(%s), %s))", src0, src1);
output_line(ctx, "%s", code);
} // emit_GLSL_POW

static void emit_GLSL_CRS(Context *ctx)
Expand Down

0 comments on commit 7e7d4e4

Please sign in to comment.