#include "client/rendering/Mesh.h" #include "rendering/Attributes.h" Mesh::Mesh() : vertices(0) { } bool Mesh::init() { vertexBuffer.init(Attributes().addFloat(3).addFloat(2).addFloat(3)); return false; } void Mesh::build(const TypedBuffer& buffer) { vertices = buffer.getLength() * 3; vertexBuffer.setStaticData(buffer.getByteLength(), buffer); } void Mesh::draw() { vertexBuffer.draw(vertices); }