Shaders: Emit an unimplemented warning for indexed vertex fetch instructions

This commit is contained in:
Dr. Chat 2016-01-13 01:50:20 -06:00
parent 14c5e48120
commit a5b37dce1d
1 changed files with 8 additions and 0 deletions

View File

@ -535,6 +535,14 @@ void GlslShaderTranslator::ProcessVertexFetchInstruction(
EmitSource("// "); EmitSource("// ");
instr.Disassemble(&source_); instr.Disassemble(&source_);
if (instr.operands[0].storage_index != 0) {
// Unimplemented for now.
EmitUnimplementedTranslationError();
EmitSourceDepth("pv.xyzw = vec4(0.0, 0.0, 0.0, 0.0);\n");
EmitStoreVectorResult(instr.result);
return;
}
if (instr.is_predicated) { if (instr.is_predicated) {
EmitSourceDepth("if (%cp0) {\n", instr.predicate_condition ? ' ' : '!'); EmitSourceDepth("if (%cp0) {\n", instr.predicate_condition ? ' ' : '!');
Indent(); Indent();