How to get the VIEW vector from SCREEN_UV in shader?
Asked Answered
S

1

0

Hi! I am making a post-processing shader and need to get the view direction of a neighbor pixel for a sort of ray cast. However I can't figure out a way to get it from just the screen uv and the matrices (I am really no math expert). Can anyone help?

Schroer answered 23/2 at 19:46 Comment(0)
E
0

Schroer You can rgb encode the vector, render it to screen and read the values in the next pass.

Ekaterina answered 23/2 at 20:44 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.