X-Git-Url: http://git.mutantstargoat.com?a=blobdiff_plain;f=src%2Fmesh.h;h=08d01d7d26cc7c703e167378e9a6b2e5237e1b78;hb=8f59fd2bda5b48b7cb9137ca5ee141dd8f8382d1;hp=7ca25c21055492beb32b24a74f408a8ca9b4314a;hpb=da5cbacf755273da510c37c819a59c7fe9894c4e;p=hair diff --git a/src/mesh.h b/src/mesh.h index 7ca25c2..08d01d7 100644 --- a/src/mesh.h +++ b/src/mesh.h @@ -10,8 +10,9 @@ enum { MESH_VERTEX = 1, MESH_NORMAL = 2, - MESH_COLOR = 4, - MESH_INDEX = 8 + MESH_TEXCOORDS = 4, + MESH_COLOR = 8, + MESH_INDEX = 16 }; struct Aabb { @@ -19,10 +20,20 @@ struct Aabb { Vec3 v1; }; +struct Material { + Vec3 diffuse; + Vec3 specular; + float shininess; + + unsigned int tex; + bool tex_opaque; +}; + class Mesh { private: unsigned int vbo_vertices; unsigned int vbo_normals; + unsigned int vbo_texcoords; unsigned int vbo_colors; unsigned int ibo; @@ -34,10 +45,12 @@ public: ~Mesh(); Aabb bbox; + Material mtl; std::string name; std::vector indices; std::vector vertices; + std::vector texcoords; std::vector normals; std::vector colors;