summaryrefslogtreecommitdiff
path: root/gfx/gl
diff options
context:
space:
mode:
Diffstat (limited to 'gfx/gl')
-rw-r--r--gfx/gl/glVertexArray.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/gfx/gl/glVertexArray.h b/gfx/gl/glVertexArray.h
index dbe930f..6630b70 100644
--- a/gfx/gl/glVertexArray.h
+++ b/gfx/gl/glVertexArray.h
@@ -40,7 +40,15 @@ namespace Impl {
}
// Customisation point
- template<typename VertexT> VertexArrayConfigurator & addAttribsFor(GLuint divisor, const glBuffer & buffer);
+ template<typename VertexT> VertexArrayConfigurator & addAttribsFor(GLuint divisor);
+
+ template<typename VertexT>
+ VertexArrayConfigurator &
+ addAttribsFor(GLuint divisor, const glBuffer & buffer)
+ {
+ glVertexArrayVertexBuffer(name, binding, buffer, 0, sizeof(VertexT));
+ return addAttribsFor<VertexT>(divisor);
+ }
template<typename VertexT, MP... Attribs>
VertexArrayConfigurator &