Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Information on what uniforms are available and what they mean. #45

Open
nezumisama opened this issue Sep 8, 2016 · 2 comments
Open

Comments

@nezumisama
Copy link

nezumisama commented Sep 8, 2016

I couldn't find information of what uniforms are available and what they do. It would be useful to provide a short explanation of each uniform.
From what I found, these uniforms are available:

float time; // Seconds since start.
vec2 mouse; // Mouse position, X and Y 0 to 1, X starts left, Y starts bottom.
vec2 resolution; // Resolution.
sampler2D backbuffer // Texture storing previous rendered image.
vec2 surfaceSize; // ???
??? texture; // ???

What's the function of surfaceSize and texture by the way?
And I know of one varying

varying vec2 surfacePosition;

But I don't know what it does.

@dagostinelli
Copy link

Agreed. It's not intuitive to me what's available either.

A simple one is what model/geometry is in gl_FragCoord? For experienced folks, some of this is obvious, but for newbies, it's not so obvious and this seems like a fantastic site to learn on.

@Zireael07
Copy link

Can we create our own uniforms?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants