src/gl/compiler.h

changeset 48
3c10f0e2fbe0
parent 47
cd6704009eb9
child 49
d56cc7387dad
--- a/src/gl/compiler.h	Thu Feb 06 23:41:20 2020 +0200
+++ b/src/gl/compiler.h	Fri Feb 07 01:58:34 2020 +0200
@@ -26,6 +26,7 @@
 #include <QOpenGLVertexArrayObject>
 #include <QOpenGLBuffer>
 #include <QOpenGLShaderProgram>
+#include <QOpenGLExtraFunctions>
 
 class Model;
 class DocumentManager;
@@ -39,11 +40,12 @@
 		glm::vec3 position;
 		glm::vec4 color;
 		glm::vec3 normal;
-		glm::vec3 id;
+		glm::vec3 idColor;
+		glm::int32 id;
 	};
 }
 
-class gl::Compiler : public QObject, protected QOpenGLFunctions
+class gl::Compiler : public QObject, protected QOpenGLExtraFunctions
 {
 	Q_OBJECT
 public:
@@ -87,6 +89,7 @@
 	bool initialized = false;
 	BoundingBox boundingBox;
 	const ldraw::ColorTable& colorTable;
+	ldraw::Id hovered = ldraw::NULL_ID;
 	struct
 	{
 		QOpenGLShaderProgram* program = nullptr;

mercurial