The enum is finally completely reimplemented for specific cases with
proper values (Mesh attribute types, index types, pixel types, ...). The
rest currently remaining in TypeTraits.h is used only in Mesh and
AbstractShaderProgram, probably will be moved there.
(De)normalization from/to [0, 1] for unsigned types and from/to [-1, 1]
for signed types. -1.0 is always denormalized to min+1.
Also updated some tests for Color, as they depended on previous
imprecise implementation.
The implementation was really frightening and it was really used only in
MeshTools::compressIndices(). Other classes like SizeTraits, Pow and Log
were just waiting to be deleted, nothing of value was lost.
Using specialized enum instead of global Type and shitload of type
traits to handle it correctly. Removed TypeTraits::indexType() and
cleaned up MeshTools::compressIndices() while at it.
If ARB_invalidate_subdata is not available, these functions do nothing,
instead of crashing on null pointer dereference. It results in more
convenient usage, enabling users to call them whenever they want,
improving performance on implementations which supports that.
Instead of having pair of functions for depth/stencil and color
attachments this is now solved using specialized class. It is now more
descriptive, as specifying color attachment is now done explicitly using
Framebuffer::ColorAttachment(2) instead of just `2`. Specifying "no
attachment" is now also done explicitly using
Framebuffer::DrawAttachment::None instead of `-1`.
Also updated related documentation.
* Error when function is missing return type (not just warning).
* Warn when functions in source don't have corresponding declarations
in header. In case that it is not an error they should be put in
anonymous namespace.
Would cause weird issues with state, it's better to just not allow it
and follow KISS principle than trying to implementing it. Also
crosslinked required function calls in documentation.
OpenGL 3.0 specification is awesomely confused with extensions. The ones
listed in specs don't have the complete functionality and references
to related ARB extensions are nowhere to be found.