Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | CravateZeus |
Hi, I’m making a screen shader that needs to read the color of each pixel in order to cast the shadow of that pixel depending on its height (each sprite has a heightmap associated).
The problem is that I’m currently reading the SCREEN_TEXTURE so I can’t access pixels outside of the screen. This means that sprites slightly outside of the player’s field of view don’t get their shadow drawn properly.
Is there a way I can render pixels a bit outside of the screen to be able to read their color values from my screen shader ?