We are about to switch to a new forum software. Until then we have removed the registration on this forum.
I've just started learning shaders and am wondering whether I should try and make my shader code somehow have the (0,0) origin in the top left if its running inside Processing?
Apparently there is a way to modify this via
layout(origin_upper_left) in vec4 gl_FragCoord;
https://khronos.org/opengl/wiki/Built-in_Variable_(GLSL)#Fragment_shader_inputs
Is this useful or needed?
Thanks
Answers
@smokeredsky , it's useful but not needed.
Opengl, (and also things like box2D) uses a Cartesian_coordinate_system .
I don't know what processing's system is called but I guess it's kind of intuitive because that's how you would read/write a book.
All you have to do is flip it upside down and it'll work anyways
Ah ok, thanks