Join GitHub today
Added colour uniform to flat shader (even when texturing is enabled) #34
This allows blending to be done (with the texture and colour).
It is quite useful as with this you can change the transparency of an object quite simply*. Also, this allows re-colouring of textures to be done. e.g. if you made a coin image for your game, and wish to have different types of coins without having to re-create assets, you could just re-colour them.
*it might be wise to actually have this as a separate uniform, with the color attribute only having RGB values.
Basically a duplicate of #33, except I:
I don't know about performance implications when having separate uniform for RGB and alpha. It should not be an issue with ARB_enhanced_layouts, which is part of GL 4.4, but on older/mobile systems
Thank you very much.