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

lazy initialize uniform.location #16

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

bejayoharen
Copy link
Contributor

This is untested but should be a performance boost when uniforms are set frequently.

This is untested but should be a performance boost when uniforms are set frequently.
@patriciogonzalezvivo
Copy link
Owner

Mmmm.... the thing is glslCanvas (that's use by glslEditor) have as a core feature of allowing you to reload different vert/frag shaders. Seams like keeping a record of the location will prevent access for future locations in case the code change and new shader programs are running

@bejayoharen
Copy link
Contributor Author

I see. In that case, this patch is no good by itself. I can dig in some more -- maybe it's possible to cache it and clear the cache when the shaders change?

@patriciogonzalezvivo
Copy link
Owner

yes, that makes a lot of sense... some sort of flag that keep track on when shaders change? right?
I feel that could work

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

Successfully merging this pull request may close these issues.

2 participants