summaryrefslogtreecommitdiff
path: root/assetFactory/cylinder.cpp
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2023-11-09 00:40:40 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2023-11-09 00:40:40 +0000
commit9c2c3f71065c94a18c02440111b6ff8ca977b90e (patch)
tree339c9846cdd6937a5e77b37f88e3ee3674f944e5 /assetFactory/cylinder.cpp
parentWIP typedefing all the things - headers (diff)
downloadilt-9c2c3f71065c94a18c02440111b6ff8ca977b90e.tar.bz2
ilt-9c2c3f71065c94a18c02440111b6ff8ca977b90e.tar.xz
ilt-9c2c3f71065c94a18c02440111b6ff8ca977b90e.zip
WIP typedefing all the things - sources
Diffstat (limited to 'assetFactory/cylinder.cpp')
-rw-r--r--assetFactory/cylinder.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/assetFactory/cylinder.cpp b/assetFactory/cylinder.cpp
index 7d22e36..ed034fd 100644
--- a/assetFactory/cylinder.cpp
+++ b/assetFactory/cylinder.cpp
@@ -9,8 +9,8 @@ Cylinder::createMesh(ModelFactoryMesh & mesh, float lodf) const
const auto step = two_pi / static_cast<float>(P);
// Generate 2D circumference points
- std::vector<glm::vec2> circumference(P);
- std::generate(circumference.begin(), circumference.end(), [a = 0.f, step]() mutable {
+ std::vector<Position2D> circumference(P);
+ std::generate(circumference.begin(), circumference.end(), [a = 0.F, step]() mutable {
return sincosf(a += step) * .5F;
});
@@ -19,7 +19,7 @@ Cylinder::createMesh(ModelFactoryMesh & mesh, float lodf) const
// Generate bottom face vertices
std::vector<OpenMesh::VertexHandle> bottom(P);
std::transform(circumference.begin(), circumference.end(), bottom.begin(), [&mesh](const auto & xy) {
- return mesh.add_vertex(xy ^ 0.f);
+ return mesh.add_vertex(xy ^ 0.F);
});
surface.insert(mesh.add_namedFace("bottom", bottom));
}