SPV: the OpImageTexelPointer sample 0 should be <id> of 0, not literal 0.
This commit is contained in:
parent
7b9fa25bad
commit
cd26144d24
2 changed files with 18 additions and 19 deletions
|
|
@ -2087,13 +2087,12 @@ spv::Id TGlslangToSpvTraverser::createImageTextureFunctionCall(glslang::TIntermO
|
|||
} else if (node->isSparseImage()) {
|
||||
spv::MissingFunctionality("sparse image functions");
|
||||
return spv::NoResult;
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
// Process image atomic operations
|
||||
|
||||
// GLSL "IMAGE_PARAMS" will involve in constructing an image texel pointer and this pointer,
|
||||
// as the first source operand, is required by SPIR-V atomic operations.
|
||||
operands.push_back(sampler.ms ? *(opIt++) : 0); // For non-MS, the value should be 0
|
||||
operands.push_back(sampler.ms ? *(opIt++) : builder.makeUintConstant(0)); // For non-MS, the value should be 0
|
||||
|
||||
spv::Id resultTypeId = builder.makePointer(spv::StorageClassImage, convertGlslangToSpvType(node->getType()));
|
||||
spv::Id pointer = builder.createOp(spv::OpImageTexelPointer, resultTypeId, operands);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue