Quantcast
Channel: AMD Developer Forums: Message List - OpenGL & Vulkan
Viewing all articles
Browse latest Browse all 631

Re: imageAtomicAdd on R16I textures

$
0
0

I'll pass on to the OpenGL team.

 

For the "how do I format code..."

 

When you reply, toward the upper right of the Reply box you should see "Use Advanced Editor." Click that.

 

You now have real formatting options, like ability to pick a font.

 

What I would so is copy and paste the code in place, select it, and apply Courier.

 

#version 430 core

 

layout(binding = 1, r16i) uniform iimage2D sampleTexture; //fail

//layout(binding =1, r32i) uniform iimage2D sampleTexture; //success

 

void main(void){

ivec2 pix = ivec2(gl_GlobalInvocationID.xy);

  imageAtomicAdd(sampleTexture, pix, 1); //if this is commented out/removed, success

}

 

(I have to go see if there's any way to create a code "style" and make this happen a bit more easily. Probably not, but what the hey... I can dream)


Viewing all articles
Browse latest Browse all 631

Trending Articles