From 69ee8f9676453981607fcdd69c8451c95b0fd50a Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Sun, 20 Apr 2008 15:50:29 -0400 Subject: [PATCH] More explicit testing for coissue bit conditions. I _still_ don't know what this does or how to express it in d3d asm, though! --HG-- branch : trunk --- mojoshader.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/mojoshader.c b/mojoshader.c index 5a92c6da..28068966 100644 --- a/mojoshader.c +++ b/mojoshader.c @@ -3989,8 +3989,15 @@ static int parse_instruction_token(Context *ctx) if ((token & 0x80000000) != 0) return fail(ctx, "instruction token high bit must be zero."); // so says msdn. - if (coissue) // !!! FIXME: I'm not sure what this means, yet. + if (coissue) + { + if (!shader_is_pixel(ctx)) + return fail(ctx, "coissue instruction on non-pixel shader"); + else if (shader_version_atleast(ctx, 2, 0)) + return fail(ctx, "coissue instruction in Shader Model >= 2.0"); + // !!! FIXME: I'm not sure what this actually means, yet. return fail(ctx, "coissue instructions unsupported"); + } // if if ((ctx->shader_type & instruction->shader_types) == 0) {