Add support for extension GL_ARB_shader_bit_encoding (#2183)
This commit is contained in:
parent
4d2298bfd7
commit
9f46e3dd5e
5 changed files with 76 additions and 3 deletions
|
|
@ -1262,7 +1262,7 @@ void TBuiltIns::initialize(int version, EProfile profile, const SpvVersion& spvV
|
|||
#endif
|
||||
|
||||
if ((profile == EEsProfile && version >= 300) ||
|
||||
(profile != EEsProfile && version >= 330)) {
|
||||
(profile != EEsProfile && version >= 150)) { // GL_ARB_shader_bit_encoding
|
||||
commonBuiltins.append(
|
||||
"int floatBitsToInt(highp float value);"
|
||||
"ivec2 floatBitsToInt(highp vec2 value);"
|
||||
|
|
@ -7816,6 +7816,13 @@ void TBuiltIns::identifyBuiltIns(int version, EProfile profile, const SpvVersion
|
|||
symbolTable.setFunctionExtensions("imageAtomicCompSwap", 1, &E_GL_OES_shader_image_atomic);
|
||||
}
|
||||
|
||||
if (profile != EEsProfile && version < 330 ) {
|
||||
symbolTable.setFunctionExtensions("floatBitsToInt", 1, &E_GL_ARB_shader_bit_encoding);
|
||||
symbolTable.setFunctionExtensions("floatBitsToUint", 1, &E_GL_ARB_shader_bit_encoding);
|
||||
symbolTable.setFunctionExtensions("intBitsToFloat", 1, &E_GL_ARB_shader_bit_encoding);
|
||||
symbolTable.setFunctionExtensions("uintBitsToFloat", 1, &E_GL_ARB_shader_bit_encoding);
|
||||
}
|
||||
|
||||
symbolTable.setVariableExtensions("gl_DeviceIndex", 1, &E_GL_EXT_device_group);
|
||||
BuiltInVariable("gl_DeviceIndex", EbvDeviceIndex, symbolTable);
|
||||
symbolTable.setVariableExtensions("gl_ViewIndex", 1, &E_GL_EXT_multiview);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue