eqemu

view src/object.cc @ 3:f9274bebe55e

adding 3d graphics stuff
author John Tsiombikas <nuclear@member.fsf.org>
date Thu, 17 Jul 2014 02:35:19 +0300
parents
children 3d3656360a82
line source
1 #include "object.h"
3 Object::Object()
4 {
5 mesh = 0;
6 }
8 void Object::set_mesh(Mesh *mesh)
9 {
10 this->mesh = mesh;
11 }
13 Mesh *Object::get_mesh() const
14 {
15 return mesh;
16 }
18 void Object::render() const
19 {
20 if(!mesh) return;
22 mtl.setup();
23 mesh->draw();
24 }