From 6ec18905acdb9b30e5bfc5eee9be0182ce1744c9 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Thu, 26 Oct 2023 20:34:55 +0100 Subject: Move OpenMesh/GLM compatibility structs to common place --- assetFactory/modelFactoryMesh.h | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) (limited to 'assetFactory') diff --git a/assetFactory/modelFactoryMesh.h b/assetFactory/modelFactoryMesh.h index 32e7ab5..2129fb5 100644 --- a/assetFactory/modelFactoryMesh.h +++ b/assetFactory/modelFactoryMesh.h @@ -2,36 +2,11 @@ #include "modelFactoryMesh_fwd.h" #include -#include #include -#include #include #include #include - -namespace glm { - template - auto - norm(const vec & v) - { - return length(v); - } - - template - auto - vectorize(vec & v, S scalar) - { - v = vec {static_cast(scalar)}; - } -} - -namespace OpenMesh { - template struct vector_traits> { - using vector_type = glm::vec; - using value_type = T; - static constexpr glm::length_t size_ = L; - }; -} +#include struct ModelFactoryTraits : public OpenMesh::DefaultTraits { FaceAttributes(OpenMesh::Attributes::Normal | OpenMesh::Attributes::Status | OpenMesh::Attributes::Color); -- cgit v1.2.3