]> git.sesse.net Git - nageru/blobdiff - glwidget.cpp
Add a HTTP server for stream output.
[nageru] / glwidget.cpp
index 9725210622ea04150b4b85386a7d55112abfbc72..3482a13391609c049869650d7aadb32481cb94ec 100644 (file)
@@ -8,6 +8,7 @@
 #include <QSurfaceFormat>
 
 #include "glwidget.h"
+#include "mainwindow.h"
 
 #include <movit/resource_pool.h>
 #include <stdio.h>
@@ -17,6 +18,7 @@
 #include "mixer.h"
 #include "ref_counted_gl_sync.h"
 
+class MainWindow;
 class QSurface;
 class QWidget;
 
@@ -24,6 +26,8 @@ class QWidget;
 #include <movit/util.h>
 #include <string>
 
+using namespace std;
+
 GLWidget::GLWidget(QWidget *parent)
     : QGLWidget(parent, global_share_widget),
       resource_pool(new movit::ResourcePool)
@@ -46,6 +50,7 @@ void GLWidget::initializeGL()
        });
        global_mixer->set_frame_ready_callback(output, [this]{
                QMetaObject::invokeMethod(this, "update", Qt::AutoConnection);
+               emit transition_names_updated(global_mixer->get_transition_names());
        });
 
        glDisable(GL_BLEND);
@@ -72,3 +77,8 @@ void GLWidget::paintGL()
        frame.chain->render_to_screen();
        check_error();
 }
+
+void GLWidget::mousePressEvent(QMouseEvent *event)
+{
+       emit clicked();
+}