GNU Radio's FOSPHOR Package

QGLSurface.h
Go to the documentation of this file.
1/* -*- c++ -*- */
2/*
3 * Copyright 2013-2014 Sylvain Munaut <tnt@246tNt.com>
4 *
5 * This is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 3, or (at your option)
8 * any later version.
9 *
10 * This software is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this software; see the file COPYING. If not, write to
17 * the Free Software Foundation, Inc., 51 Franklin Street,
18 * Boston, MA 02110-1301, USA.
19 */
20
21#ifndef INCLUDED_GR_FOSPHOR_QGLSURFACE_H
22#define INCLUDED_GR_FOSPHOR_QGLSURFACE_H
23
24#include <QGLWidget>
25
26 class QThread;
27
28 namespace gr {
29 namespace fosphor {
30
31 class qt_sink_c_impl;
32
33 class QGLSurface : public ::QGLWidget
34 {
35 Q_OBJECT
36
37 qt_sink_c_impl *d_block;
38 QThread *d_gui_thread;
39
40 protected:
41 void hideEvent(QHideEvent *he);
42 void showEvent(QShowEvent *he);
43 void paintEvent(QPaintEvent *pe);
44 void resizeEvent(QResizeEvent *re);
45 void keyPressEvent(QKeyEvent *ke);
46
47 private slots:
48 void giveContext(QThread *thread);
49
50 public:
51 QGLSurface(QWidget *parent, qt_sink_c_impl *d_block);
52
53 void grabContext();
54 void releaseContext();
55 };
56
57 } // namespace fosphor
58} // namespace gr
59
60#endif /* INCLUDED_GR_FOSPHOR_QGLSURFACE_H */
gr::fosphor::QGLSurface
Definition: QGLSurface.h:34
gr::fosphor::QGLSurface::QGLSurface
QGLSurface(QWidget *parent, qt_sink_c_impl *d_block)
gr::fosphor::QGLSurface::hideEvent
void hideEvent(QHideEvent *he)
gr::fosphor::QGLSurface::keyPressEvent
void keyPressEvent(QKeyEvent *ke)
gr::fosphor::QGLSurface::paintEvent
void paintEvent(QPaintEvent *pe)
gr::fosphor::QGLSurface::resizeEvent
void resizeEvent(QResizeEvent *re)
gr::fosphor::QGLSurface::showEvent
void showEvent(QShowEvent *he)
gr::fosphor::QGLSurface::releaseContext
void releaseContext()
gr::fosphor::QGLSurface::grabContext
void grabContext()
gr::fosphor::qt_sink_c_impl
Qt version of fosphor sink (implementation)
Definition: qt_sink_c_impl.h:39
gr
Definition: base_sink_c.h:30
fosphor
Definition: private.h:44