+VertexArray::Loader::Loader(VertexArray &a):
+ VertexArrayBuilder(a)
+{
+ add("vertex2", static_cast<void (Loader::*)(float, float)>(&Loader::vertex));
+ add("vertex3", static_cast<void (Loader::*)(float, float, float)>(&Loader::vertex));
+ add("vertex4", static_cast<void (Loader::*)(float, float, float, float)>(&Loader::vertex));
+ add("normal3", static_cast<void (Loader::*)(float, float, float)>(&Loader::normal));
+ add("texcoord1", static_cast<void (Loader::*)(float)>(&Loader::texcoord));
+ add("texcoord2", static_cast<void (Loader::*)(float, float)>(&Loader::texcoord));
+ add("texcoord3", static_cast<void (Loader::*)(float, float, float)>(&Loader::texcoord));
+ add("texcoord4", static_cast<void (Loader::*)(float, float, float, float)>(&Loader::texcoord));
+ add("color3", static_cast<void (Loader::*)(float, float, float)>(&Loader::color));
+ add("color4", static_cast<void (Loader::*)(float, float, float, float)>(&Loader::color));
+ add("attrib1", static_cast<void (Loader::*)(unsigned, float)>(&Loader::attrib));
+ add("attrib2", static_cast<void (Loader::*)(unsigned, float, float)>(&Loader::attrib));
+ add("attrib3", static_cast<void (Loader::*)(unsigned, float, float, float)>(&Loader::attrib));
+ add("attrib4", static_cast<void (Loader::*)(unsigned, float, float, float, float)>(&Loader::attrib));
+}
+
+
+void array_element(int i)
+{
+ glArrayElement(i);
+}
+
+void draw_arrays(PrimitiveType mode, int first, sizei count)
+{
+ glDrawArrays(mode, first, count);
+}
+
+void draw_elements(PrimitiveType mode, sizei count, DataType type, const void *indices)
+{
+ glDrawElements(mode, count, type, indices);
+}
+
+void draw_range_elements(PrimitiveType mode, uint low, uint high, sizei count, DataType type, const void *indices)
+{
+ static RequireVersion _ver(1, 2);
+ glDrawRangeElements(mode, low, high, count, type, indices);
+}
+