Updated local clang-format.
This commit is contained in:
parent
740c70f270
commit
38094ac819
|
@ -672,11 +672,11 @@ void ShaderTranslator::TranslateExecInstructions(
|
||||||
static_cast<FetchOpcode>(ucode_dwords_[instr_offset * 3] & 0x1F);
|
static_cast<FetchOpcode>(ucode_dwords_[instr_offset * 3] & 0x1F);
|
||||||
if (fetch_opcode == FetchOpcode::kVertexFetch) {
|
if (fetch_opcode == FetchOpcode::kVertexFetch) {
|
||||||
auto& op = *reinterpret_cast<const VertexFetchInstruction*>(
|
auto& op = *reinterpret_cast<const VertexFetchInstruction*>(
|
||||||
ucode_dwords_ + instr_offset * 3);
|
ucode_dwords_ + instr_offset * 3);
|
||||||
TranslateVertexFetchInstruction(op);
|
TranslateVertexFetchInstruction(op);
|
||||||
} else {
|
} else {
|
||||||
auto& op = *reinterpret_cast<const TextureFetchInstruction*>(
|
auto& op = *reinterpret_cast<const TextureFetchInstruction*>(
|
||||||
ucode_dwords_ + instr_offset * 3);
|
ucode_dwords_ + instr_offset * 3);
|
||||||
TranslateTextureFetchInstruction(op);
|
TranslateTextureFetchInstruction(op);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -237,9 +237,8 @@ void SpirvShaderTranslator::StartTranslation() {
|
||||||
b.addDecoration(attrib_var, spv::Decoration::DecorationLocation,
|
b.addDecoration(attrib_var, spv::Decoration::DecorationLocation,
|
||||||
attrib.attrib_index);
|
attrib.attrib_index);
|
||||||
|
|
||||||
vertex_binding_map_[binding.fetch_constant][attrib.fetch_instr
|
vertex_binding_map_[binding.fetch_constant]
|
||||||
.attributes.offset] =
|
[attrib.fetch_instr.attributes.offset] = attrib_var;
|
||||||
attrib_var;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -636,9 +635,8 @@ void SpirvShaderTranslator::ProcessVertexFetchInstruction(
|
||||||
// Operand 0 is the index
|
// Operand 0 is the index
|
||||||
// Operand 1 is the binding
|
// Operand 1 is the binding
|
||||||
// TODO: Indexed fetch
|
// TODO: Indexed fetch
|
||||||
auto vertex_ptr =
|
auto vertex_ptr = vertex_binding_map_[instr.operands[1].storage_index]
|
||||||
vertex_binding_map_[instr.operands[1].storage_index][instr.attributes
|
[instr.attributes.offset];
|
||||||
.offset];
|
|
||||||
assert_not_zero(vertex_ptr);
|
assert_not_zero(vertex_ptr);
|
||||||
|
|
||||||
auto vertex = b.createLoad(vertex_ptr);
|
auto vertex = b.createLoad(vertex_ptr);
|
||||||
|
|
Loading…
Reference in New Issue