summaryrefslogtreecommitdiff
path: root/assetFactory/modelFactoryMesh.h
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2023-03-18 02:44:00 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2023-03-18 02:44:00 +0000
commit51f0f60bd24a3d7ed77cf713f846bc49c2f1aed5 (patch)
treeb4b7acb17274e1753a002956bcddebb691c40762 /assetFactory/modelFactoryMesh.h
parentUse indices instead of triangulation (diff)
downloadilt-51f0f60bd24a3d7ed77cf713f846bc49c2f1aed5.tar.bz2
ilt-51f0f60bd24a3d7ed77cf713f846bc49c2f1aed5.tar.xz
ilt-51f0f60bd24a3d7ed77cf713f846bc49c2f1aed5.zip
Use halfedge for texture coordinates
More unique than vertex as it is also per face, allowing for a different texture on adjacent faces
Diffstat (limited to 'assetFactory/modelFactoryMesh.h')
-rw-r--r--assetFactory/modelFactoryMesh.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/assetFactory/modelFactoryMesh.h b/assetFactory/modelFactoryMesh.h
index 493ce1b..a862dc1 100644
--- a/assetFactory/modelFactoryMesh.h
+++ b/assetFactory/modelFactoryMesh.h
@@ -35,7 +35,8 @@ namespace OpenMesh {
struct ModelFactoryTraits : public OpenMesh::DefaultTraits {
FaceAttributes(OpenMesh::Attributes::Normal | OpenMesh::Attributes::Status | OpenMesh::Attributes::Color);
EdgeAttributes(OpenMesh::Attributes::Status);
- VertexAttributes(OpenMesh::Attributes::Normal | OpenMesh::Attributes::Status | OpenMesh::Attributes::TexCoord2D);
+ VertexAttributes(OpenMesh::Attributes::Normal | OpenMesh::Attributes::Status);
+ HalfedgeAttributes(OpenMesh::Attributes::TexCoord2D);
using Point = glm::vec3;
using Normal = glm::vec3;
using Color = glm::vec4;