From 38828181aa0ea7f9a70db50cf5e15a18f4be224f Mon Sep 17 00:00:00 2001 From: Maxime Gimeno Date: Fri, 15 Mar 2019 15:38:44 +0100 Subject: [PATCH] Dont call mat3() constructor --- GraphicsView/include/CGAL/Qt/Basic_viewer_qt.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/GraphicsView/include/CGAL/Qt/Basic_viewer_qt.h b/GraphicsView/include/CGAL/Qt/Basic_viewer_qt.h index 944aa973fcf..c809ab05e8a 100644 --- a/GraphicsView/include/CGAL/Qt/Basic_viewer_qt.h +++ b/GraphicsView/include/CGAL/Qt/Basic_viewer_qt.h @@ -162,7 +162,11 @@ const char vertex_source_color_comp[] = "void main(void)\n" "{\n" " fP = mv_matrix * vertex; \n" - " fN = mat3(mv_matrix)* normal; \n" + " mat3 mv_matrix_3; \n" + " mv_matrix_3[0] = mv_matrix[0].xyz; \n" + " mv_matrix_3[1] = mv_matrix[1].xyz; \n" + " mv_matrix_3[2] = mv_matrix[2].xyz; \n" + " fN = mv_matrix_3* normals; \n" " fColor = vec4(color, 1.0); \n" " gl_PointSize = point_size;\n" " gl_Position = mvp_matrix * vertex;\n"