Skip to content

Simplified updating interface and caching improvements#12

Open
mikolalysenko wants to merge 9 commits into
masterfrom
rewrite-source
Open

Simplified updating interface and caching improvements#12
mikolalysenko wants to merge 9 commits into
masterfrom
rewrite-source

Conversation

@mikolalysenko
Copy link
Copy Markdown
Member

This change set replaces .updateExports() with a simpler method called .update(). This new method takes a new vertex/fragment shader runs them.

If there is a down vote on this, then I will merge this change set into gl-shader.

Longer term, I think that maybe glslify should move to sourceOnly as the default and only option, then the particular choice of shader wrapper wouldn't matter as much.

@mikolalysenko
Copy link
Copy Markdown
Member Author

Summary of changes:

  • Change handle to program
  • Implement caching and reference counting for shader objects (improves performance when attribute locations are changed)
  • Remove .updateExports()
  • Add a new .update() method which reruns the constructor (similar to behavior from gl-buffer, gl-fbo, etc.)
  • Fix a bug with attribute locations not working correctly
  • Make default attribute locations deterministic across different WebGL implementations
  • Add an option for using runtime reflection to load uniforms/attributes if not specified by glslify or otherwise

@mikolalysenko mikolalysenko changed the title Rewrite source Simplified updating interface and caching improvements Dec 6, 2014
@mikolalysenko mikolalysenko mentioned this pull request Dec 9, 2014
15 tasks
@hughsk
Copy link
Copy Markdown
Member

hughsk commented Dec 9, 2014

Looks good to me! :)

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