diff options
author | Roland Scheidegger <[email protected]> | 2009-12-18 23:53:25 +0100 |
---|---|---|
committer | Roland Scheidegger <[email protected]> | 2009-12-18 23:53:25 +0100 |
commit | ff5b0c72db20be099f9fc7dee22aeebbda75ab42 (patch) | |
tree | af160275bb16586db51666c818a5d1dad8209634 /src/gallium/auxiliary/tgsi/tgsi_scan.c | |
parent | 9d938e29f202552a98605906b71f31485af1ef60 (diff) |
gallium: store edgflag info in tgsi_shader_info
provides easier access for drivers which may base fallback decision on this
Diffstat (limited to 'src/gallium/auxiliary/tgsi/tgsi_scan.c')
-rw-r--r-- | src/gallium/auxiliary/tgsi/tgsi_scan.c | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/src/gallium/auxiliary/tgsi/tgsi_scan.c b/src/gallium/auxiliary/tgsi/tgsi_scan.c index a5d2db04ec1..ebee000c06e 100644 --- a/src/gallium/auxiliary/tgsi/tgsi_scan.c +++ b/src/gallium/auxiliary/tgsi/tgsi_scan.c @@ -138,15 +138,19 @@ tgsi_scan_shader(const struct tgsi_token *tokens, info->output_semantic_name[reg] = (ubyte)fulldecl->Semantic.Name; info->output_semantic_index[reg] = (ubyte)fulldecl->Semantic.Index; info->num_outputs++; - } - /* special case */ - if (procType == TGSI_PROCESSOR_FRAGMENT && - file == TGSI_FILE_OUTPUT && - fulldecl->Semantic.Name == TGSI_SEMANTIC_POSITION) { - info->writes_z = TRUE; + /* extra info for special outputs */ + if (procType == TGSI_PROCESSOR_FRAGMENT && + fulldecl->Semantic.Name == TGSI_SEMANTIC_POSITION) { + info->writes_z = TRUE; + } + if (procType == TGSI_PROCESSOR_VERTEX && + fulldecl->Semantic.Name == TGSI_SEMANTIC_EDGEFLAG) { + info->writes_edgeflag = TRUE; + } } - } + + } } break; |