QScreenRayCaster Class

class Qt3DRender::QScreenRayCaster

Performe ray casting test based on screen coordinates. More...

Header: #include <QScreenRayCaster>
qmake: QT += 3drender
Since: Qt 5.11
Instantiated By: ScreenRayCaster
Inherits: Qt3DRender::QAbstractRayCaster

This class was introduced in Qt 5.11.

Public Functions

void trigger()
void trigger(const QPoint &position)

Detailed Description

QScreenRayCaster can be used to perform ray casting tests by specifying coordinates in screen space, which will be used to construct an actual 3D ray between the near and far planes.

See also QRayCaster and QNoPicking.

Member Function Documentation

void QScreenRayCaster::trigger()

Convenience method to enable the component and trigger tests using the current coordinate value.

void QScreenRayCaster::trigger(const QPoint &position)

Convenience method to set the coordinate value position and enable the component to trigger tests.