HLSL: Add support for printf().
Translate printf() to what GL_EXT_debug_printf has done. HLSL could define non-constant string variable and we don't have such features in SPIR-V, so just support constant string variable.
This commit is contained in:
parent
3b334b2b8e
commit
f6e0fe8600
9 changed files with 216 additions and 5 deletions
|
|
@ -1321,6 +1321,9 @@ static void OutputConstantUnion(TInfoSink& out, const TIntermTyped* node, const
|
|||
out.debug << buf << "\n";
|
||||
}
|
||||
break;
|
||||
case EbtString:
|
||||
out.debug << "\"" << constUnion[i].getSConst()->c_str() << "\"\n";
|
||||
break;
|
||||
default:
|
||||
out.info.message(EPrefixInternalError, "Unknown constant", node->getLoc());
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue