131 Plane planeFromTriangle(const Triangle& triangle); |
131 Plane planeFromTriangle(const Triangle& triangle); |
132 glm::vec3 normalVector(const Triangle& triangle); |
132 glm::vec3 normalVector(const Triangle& triangle); |
133 std::optional<glm::vec3> linePlaneIntersection( |
133 std::optional<glm::vec3> linePlaneIntersection( |
134 const Line<3>& line, |
134 const Line<3>& line, |
135 const Plane& plane, const float epsilon = 1e-6f); |
135 const Plane& plane, const float epsilon = 1e-6f); |
136 glm::vec3 scalingVector(const glm::mat4 matrix); |
136 glm::vec3 calculate_matrix_scaling(const glm::mat4 matrix); |
137 LineSegment2D top(const QRectF& rectangle); |
137 LineSegment2D top(const QRectF& rectangle); |
138 LineSegment2D bottom(const QRectF& rectangle); |
138 LineSegment2D bottom(const QRectF& rectangle); |
139 LineSegment2D left(const QRectF& rectangle); |
139 LineSegment2D left(const QRectF& rectangle); |
140 LineSegment2D right(const QRectF& rectangle); |
140 LineSegment2D right(const QRectF& rectangle); |
141 enum class convexity_e { concave, convex }; |
141 enum class convexity_e { concave, convex }; |
142 convexity_e quadrilateral_convexity(const Quadrilateral& quad); |
142 convexity_e quadrilateral_convexity(const Quadrilateral& quad); |
143 convexity_e polygon_convexity(const std::vector<glm::vec3>& polygon); |
143 convexity_e polygon_convexity(const std::vector<glm::vec3>& polygon); |
144 Winding winding(const QPolygonF& polygon); |
144 Winding winding(const QPolygonF& polygon); |
145 struct ScalingExtract |
145 struct unscaled_matrix |
146 { |
146 { |
147 glm::vec3 scaling; |
147 glm::vec3 scaling; |
148 glm::mat4 unscaled; |
148 glm::mat4 unscaled; |
149 }; |
149 }; |
150 ScalingExtract extractScaling(const glm::mat4& matrix); |
150 unscaled_matrix unscale_matrix(const glm::mat4& matrix); |
151 |
151 |
152 struct NPolygon |
152 struct NPolygon |
153 { |
153 { |
154 std::vector<glm::vec3> points; |
154 std::vector<glm::vec3> points; |
155 }; |
155 }; |