Forgot your password?
Or sign in with one of these services
See all followers
The recent visitors block is disabled and is not being shown to other users.
See all updates by Josh
I am very surprised but it appears that declaring variables outside of any shader function results in a very significant performance increase.
My guess is that it's not redefining values each pass but I wouldn't know it would preform better.
I believe lua also behaves like that.
GPUs are so good at optimizing shader code, I assumed it just did something like this automatically under the hood.