X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=glwidget.h;h=857d733c42cf90e77ee51bf97aecdecea03d2231;hb=8c2ebd3fdae0bd663ed02098a693078e87d49451;hp=ae4902c12b1f51464981a6a2bd8c55fb78071e5d;hpb=6b5c8411a2776e77d1bb7d66ee7ec255428f2a13;p=nageru diff --git a/glwidget.h b/glwidget.h index ae4902c..857d733 100644 --- a/glwidget.h +++ b/glwidget.h @@ -13,6 +13,12 @@ class QMouseEvent; class QWidget; +namespace movit { + +class ResourcePool; + +} // namespace movit + // Note: We use the older QGLWidget instead of QOpenGLWidget as it is // much faster (does not go through a separate offscreen rendering step). // @@ -23,13 +29,14 @@ class GLWidget : public QGLWidget public: GLWidget(QWidget *parent = 0); - ~GLWidget(); void set_output(Mixer::Output output) { this->output = output; } + void clean_context(); + protected: void initializeGL() override; void resizeGL(int width, int height) override; @@ -45,6 +52,7 @@ private: Mixer::Output output; GLuint vao, program_num; GLuint position_vbo, texcoord_vbo; + movit::ResourcePool *resource_pool = nullptr; }; #endif