2cc374a0c8
Buffer objects can contain arbitrary pointers to blocks. We can also implement ConvertPtrToU and ConvertUToPtr. The latter can cast a uint64_t to any type as it pleases, so we will need to generate fake buffer reference blocks to be able to cast the type.
22 lines
387 B
Plaintext
22 lines
387 B
Plaintext
#version 450
|
|
#extension GL_ARB_gpu_shader_int64 : require
|
|
#extension GL_EXT_buffer_reference : require
|
|
layout(local_size_x = 1, local_size_y = 1, local_size_z = 1) in;
|
|
|
|
layout(buffer_reference) buffer uintPointer
|
|
{
|
|
uint value;
|
|
};
|
|
|
|
layout(push_constant, std430) uniform _4_12
|
|
{
|
|
uint64_t _m0;
|
|
} _12;
|
|
|
|
void main()
|
|
{
|
|
uintPointer _3 = uintPointer(_12._m0);
|
|
_3.value = 20u;
|
|
}
|
|
|