OSG  3.4.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
osgQt::GLWidget Class Reference

#include <GraphicsWindowQt.h>

Inheritance diagram for osgQt::GLWidget:
Inheritance graph
[legend]
Collaboration diagram for osgQt::GLWidget:
Collaboration graph
[legend]

Public Member Functions

 GLWidget (QWidget *parent=NULL, const QGLWidget *shareWidget=NULL, Qt::WindowFlags f=0, bool forwardKeyEvents=false)
 
 GLWidget (QGLContext *context, QWidget *parent=NULL, const QGLWidget *shareWidget=NULL, Qt::WindowFlags f=0, bool forwardKeyEvents=false)
 
 GLWidget (const QGLFormat &format, QWidget *parent=NULL, const QGLWidget *shareWidget=NULL, Qt::WindowFlags f=0, bool forwardKeyEvents=false)
 
virtual ~GLWidget ()
 
void setGraphicsWindow (GraphicsWindowQt *gw)
 
GraphicsWindowQtgetGraphicsWindow ()
 
const GraphicsWindowQtgetGraphicsWindow () const
 
bool getForwardKeyEvents () const
 
virtual void setForwardKeyEvents (bool f)
 
bool getTouchEventsEnabled () const
 
void setTouchEventsEnabled (bool e)
 
void setKeyboardModifiers (QInputEvent *event)
 
virtual void keyPressEvent (QKeyEvent *event)
 
virtual void keyReleaseEvent (QKeyEvent *event)
 
virtual void mousePressEvent (QMouseEvent *event)
 
virtual void mouseReleaseEvent (QMouseEvent *event)
 
virtual void mouseDoubleClickEvent (QMouseEvent *event)
 
virtual void mouseMoveEvent (QMouseEvent *event)
 
virtual void wheelEvent (QWheelEvent *event)
 
virtual bool gestureEvent (QGestureEvent *event)
 

Protected Member Functions

int getNumDeferredEvents ()
 
void enqueueDeferredEvent (QEvent::Type eventType, QEvent::Type removeEventType=QEvent::None)
 
void processDeferredEvents ()
 
virtual void resizeEvent (QResizeEvent *event)
 
virtual void moveEvent (QMoveEvent *event)
 
virtual void glDraw ()
 
virtual bool event (QEvent *event)
 

Protected Attributes

GraphicsWindowQt_gw
 
QMutex _deferredEventQueueMutex
 
QQueue< QEvent::Type > _deferredEventQueue
 
QSet< QEvent::Type > _eventCompressor
 
bool _touchEventsEnabled
 
bool _forwardKeyEvents
 
qreal _devicePixelRatio
 

Friends

class GraphicsWindowQt
 

Detailed Description

Definition at line 55 of file GraphicsWindowQt.h.

Constructor & Destructor Documentation

osgQt::GLWidget::GLWidget ( QWidget *  parent = NULL,
const QGLWidget *  shareWidget = NULL,
Qt::WindowFlags  f = 0,
bool  forwardKeyEvents = false 
)
osgQt::GLWidget::GLWidget ( QGLContext *  context,
QWidget *  parent = NULL,
const QGLWidget *  shareWidget = NULL,
Qt::WindowFlags  f = 0,
bool  forwardKeyEvents = false 
)
osgQt::GLWidget::GLWidget ( const QGLFormat &  format,
QWidget *  parent = NULL,
const QGLWidget *  shareWidget = NULL,
Qt::WindowFlags  f = 0,
bool  forwardKeyEvents = false 
)
virtual osgQt::GLWidget::~GLWidget ( )
virtual

Member Function Documentation

void osgQt::GLWidget::enqueueDeferredEvent ( QEvent::Type  eventType,
QEvent::Type  removeEventType = QEvent::None 
)
inlineprotected

Definition at line 94 of file GraphicsWindowQt.h.

virtual bool osgQt::GLWidget::event ( QEvent *  event)
protectedvirtual
virtual bool osgQt::GLWidget::gestureEvent ( QGestureEvent *  event)
virtual
bool osgQt::GLWidget::getForwardKeyEvents ( ) const
inline

Definition at line 70 of file GraphicsWindowQt.h.

GraphicsWindowQt* osgQt::GLWidget::getGraphicsWindow ( )
inline

Definition at line 67 of file GraphicsWindowQt.h.

const GraphicsWindowQt* osgQt::GLWidget::getGraphicsWindow ( ) const
inline

Definition at line 68 of file GraphicsWindowQt.h.

int osgQt::GLWidget::getNumDeferredEvents ( )
inlineprotected

Definition at line 89 of file GraphicsWindowQt.h.

bool osgQt::GLWidget::getTouchEventsEnabled ( ) const
inline

Definition at line 73 of file GraphicsWindowQt.h.

virtual void osgQt::GLWidget::glDraw ( )
protectedvirtual
virtual void osgQt::GLWidget::keyPressEvent ( QKeyEvent *  event)
virtual
virtual void osgQt::GLWidget::keyReleaseEvent ( QKeyEvent *  event)
virtual
virtual void osgQt::GLWidget::mouseDoubleClickEvent ( QMouseEvent *  event)
virtual
virtual void osgQt::GLWidget::mouseMoveEvent ( QMouseEvent *  event)
virtual
virtual void osgQt::GLWidget::mousePressEvent ( QMouseEvent *  event)
virtual
virtual void osgQt::GLWidget::mouseReleaseEvent ( QMouseEvent *  event)
virtual
virtual void osgQt::GLWidget::moveEvent ( QMoveEvent *  event)
protectedvirtual
void osgQt::GLWidget::processDeferredEvents ( )
protected
virtual void osgQt::GLWidget::resizeEvent ( QResizeEvent *  event)
protectedvirtual
virtual void osgQt::GLWidget::setForwardKeyEvents ( bool  f)
inlinevirtual

Definition at line 71 of file GraphicsWindowQt.h.

void osgQt::GLWidget::setGraphicsWindow ( GraphicsWindowQt gw)
inline

Definition at line 66 of file GraphicsWindowQt.h.

void osgQt::GLWidget::setKeyboardModifiers ( QInputEvent *  event)
void osgQt::GLWidget::setTouchEventsEnabled ( bool  e)
virtual void osgQt::GLWidget::wheelEvent ( QWheelEvent *  event)
virtual

Friends And Related Function Documentation

friend class GraphicsWindowQt
friend

Definition at line 112 of file GraphicsWindowQt.h.

Member Data Documentation

QQueue<QEvent::Type> osgQt::GLWidget::_deferredEventQueue
protected

Definition at line 116 of file GraphicsWindowQt.h.

QMutex osgQt::GLWidget::_deferredEventQueueMutex
protected

Definition at line 115 of file GraphicsWindowQt.h.

qreal osgQt::GLWidget::_devicePixelRatio
protected

Definition at line 122 of file GraphicsWindowQt.h.

QSet<QEvent::Type> osgQt::GLWidget::_eventCompressor
protected

Definition at line 117 of file GraphicsWindowQt.h.

bool osgQt::GLWidget::_forwardKeyEvents
protected

Definition at line 121 of file GraphicsWindowQt.h.

GraphicsWindowQt* osgQt::GLWidget::_gw
protected

Definition at line 113 of file GraphicsWindowQt.h.

bool osgQt::GLWidget::_touchEventsEnabled
protected

Definition at line 119 of file GraphicsWindowQt.h.


The documentation for this class was generated from the following file: