src/linetypes/triangle.cpp

changeset 21
0133e565e072
parent 18
918b6c0f8b5b
child 26
3a9e761e4faa
--- a/src/linetypes/triangle.cpp	Sat Dec 14 23:00:01 2019 +0200
+++ b/src/linetypes/triangle.cpp	Wed Jan 01 17:45:56 2020 +0200
@@ -57,3 +57,16 @@
 		vertexToStringParens(points[1]),
 		vertexToStringParens(points[2]));
 }
+
+void linetypes::Triangle::getPolygons(
+	std::vector<gl::Polygon>& polygons,
+	GetPolygonsContext* context) const
+{
+	Q_UNUSED(context)
+	polygons.push_back(gl::triangle(
+		this->points[0],
+		this->points[1],
+		this->points[2],
+		this->colorIndex,
+		this->id));
+}

mercurial