Hey!
Sooo, basically I have two related questions:
I was wondering how I can read from a random position on an input attachment inside the fragment shader?
I have following Input Attachment:
layout (input_attachment_index = 1, set = 0, binding = 1) uniform subpassInput colAttachment;
And I can read the current position perfectly fine with:
someColor = subpassLoad(colAttachment);
Everything works fine.
But is there a way I can read a random location from the attachment? I tried texelFetch, but it is only giving me errors on compile.
My other question is, is it possible to use a single color attachment as both an input (as above) and as an output?
Specifically I’m trying to do some post-processing that requires me to sample a small area around a pixel (blurring).