3 This file is part of libmspgl
4 Copyright © 2007 Mikko Rasa, Mikkosoft Productions
5 Distributed under the LGPL
18 vertices.use_vertex_buffer();
21 void Mesh::draw() const
24 for(list<Batch>::const_iterator i=batches.begin(); i!=batches.end(); ++i)
29 Mesh::Loader::Loader(Mesh &m):
32 add("vertices", &Loader::vertices);
33 add("batch", &Loader::batch);
36 void Mesh::Loader::vertices(VertexFormat f)
38 mesh.vertices.reset(f);
39 load_sub(mesh.vertices);
42 void Mesh::Loader::batch(PrimitiveType p)
44 mesh.batches.push_back(Batch(p));
45 load_sub(mesh.batches.back());