From 80fa232fafbafc93dce11bd07a52e0d71497b10a Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sat, 19 Apr 2008 04:59:27 -0400 Subject: [PATCH] Commented out apparently-bogus validity check. MOD_SATURATE is showing up in pixel shaders generated from Microsoft's HLSL compiler, so either I misread the spec when I thought this modifier was vertex-shader-specific, or the spec is wrong. Will check later. --HG-- branch : trunk --- mojoshader.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mojoshader.c b/mojoshader.c index 03e272dc..613e566c 100644 --- a/mojoshader.c +++ b/mojoshader.c @@ -2951,11 +2951,15 @@ static int parse_destination_token(Context *ctx, DestArgInfo *info) return fail(ctx, "Result shift scale isn't 1 to 3, or 13 to 15."); } // if + // !!! FIXME: these are definitely showing up in valid pixel shaders. + // !!! FIXME: go re-read the spec on this one. + #if 0 if (info->result_mod & MOD_SATURATE) // Saturate (vertex shaders only) { if (ctx->shader_type != MOJOSHADER_TYPE_VERTEX) return fail(ctx, "Saturate result mod in non-vertex shader"); } // if + #endif if (info->result_mod & MOD_PP) // Partial precision (pixel shaders only) {