namespace for both types

This commit is contained in:
David Carlier
2018-07-29 17:15:29 +01:00
parent 3928570ce4
commit bc432345a4
2 changed files with 21 additions and 13 deletions
+8 -4
View File
@@ -43,10 +43,7 @@ const char* bmfHead = "BMF ";
namespace render {
struct UV {
float u, v;
};
namespace bmf {
struct VertexIndex {
unsigned a, b, c;
@@ -57,7 +54,14 @@ struct VertexIndex {
return memcmp(this, &other, sizeof(unsigned) * 3) < 0;
}
};
}
using namespace bmf;
struct UV {
float u, v;
};
void loadBinaryMesh(const char* filename, Mesh& mesh) {
static_assert(sizeof(vec3f) == 12, "vec3f must be the size of 3 floats");