Skip to content
Snippets Groups Projects
Commit 01d4bb27 authored by Yoel's avatar Yoel
Browse files

Clear triangle vector

parent a9ccb0c4
No related branches found
No related tags found
No related merge requests found
......@@ -22,6 +22,7 @@ TriangleMesh::TriangleMesh(std::istream& in,
std::vector<std::shared_ptr<Triangle>> v;
for (auto tri : triangles) v.push_back(std::make_shared<Triangle>(tri));
hierarch(0, v);
triangles.clear();
}
std::optional<cam::Hit> TriangleMesh::intersect(const cam::Ray& r) const {
return intersect(0, r);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment