Cryru / Emotion

A game engine.
MIT License
56 stars 5 forks source link

Implement UBO for SyncShader #57

Open Cryru opened 4 years ago

Cryru commented 4 years ago

When a shader is bound the base variables (mvp matrix, iTime, iResolution etc) must be synced to it. Currently, this is done through multiple glUniform calls, but it can be optimized to use a UBO.

This could potentially be a breaking change to the shader format as those variables are not in blocks.