Qt 5.8 | Qt 3D | C++ Classes | QPickingSettings

Qt 5.8.0 Reference Documentation

# QPickingSettings Class

(Qt3DRender::QPickingSettings)

The QPickingSettings class specifies how entity picking is handled. More...

Header: | #include <QPickingSettings>
qmake: | QT += 3drender
Since: | Qt 5.7
Instantiated By: | PickingSettings
Inherits: | Qt3DCore::QNode

- List of all members, including inherited members

## Public Types

enum | FaceOrientationPickingMode { FrontFace, BackFace, FrontAndBackFace }
enum | PickMethod { BoundingVolumePicking, TrianglePicking }
enum | PickResultMode { NearestPick, AllPicks }

## Properties

- faceOrientationPickingMode : FaceOrientationPickingMode
- pickMethod : PickMethod
- pickResultMode : PickResultMode

- 2 properties inherited from Qt3DCore::QNode

## Public Functions

| QPickingSettings(Qt3DCore::QNode *parent = nullptr)
FaceOrientationPickingMode | faceOrientationPickingMode() const
PickMethod | pickMethod() const
PickResultMode | pickResultMode() const

- 6 public functions inherited from Qt3DCore::QNode

## Public Slots

void | setFaceOrientationPickingMode(FaceOrientationPickingMode faceOrientationPickingMode)
void | setPickMethod(PickMethod pickMethod)
void | setPickResultMode(PickResultMode pickResultMode)

- 2 public slots inherited from Qt3DCore::QNode

## Signals

void | faceOrientationPickingModeChanged(QPickingSettings::FaceOrientationPickingMode faceOrientationPickingMode)
void | pickMethodChanged(QPickingSettings::PickMethod pickMethod)
void | pickResultModeChanged(QPickingSettings::PickResultMode pickResult)

- 3 signals inherited from Qt3DCore::QNode

### Additional Inherited Members

- 2 protected functions inherited from Qt3DCore::QNode

## Detailed Description

The QPickingSettings class specifies how entity picking is handled.

The picking settings determine how the entity picking is handled. For more details about entity picking, see QObjectPicker component documentation.

## Member Type Documentation

### enum QPickingSettings::FaceOrientationPickingMode

### enum QPickingSettings::PickMethod

Specifies the picking method.

Constant | Value | Description
--- | --- | ---
`Qt3DRender::QPickingSettings::BoundingVolumePicking` | `0` | An entity is considered picked if the picking ray intersects the bounding volume of the entity.
`Qt3DRender::QPickingSettings::TrianglePicking` | `1` | An entity is considered picked if the picking ray intersects with any triangle of the entity's mesh component.

### enum QPickingSettings::PickResultMode

Specifies what is included into the picking results.

Constant | Value | Description
--- | --- | ---
`Qt3DRender::QPickingSettings::NearestPick` | `0` | Only the nearest entity to picking ray origin intersected by the picking ray is picked.
`Qt3DRender::QPickingSettings::AllPicks` | `1` | All entities that intersect the picking ray are picked.

## Property Documentation

### faceOrientationPickingMode : FaceOrientationPickingMode

Access functions:

FaceOrientationPickingMode | faceOrientationPickingMode() const
void | setFaceOrientationPickingMode(FaceOrientationPickingMode faceOrientationPickingMode)

Notifier signal:

void | faceOrientationPickingModeChanged(QPickingSettings::FaceOrientationPickingMode faceOrientationPickingMode)

### pickMethod : PickMethod

Holds the current pick method.

Access functions:

PickMethod | pickMethod() const
void | setPickMethod(PickMethod pickMethod)

Notifier signal:

void | pickMethodChanged(QPickingSettings::PickMethod pickMethod)

### pickResultMode : PickResultMode

Holds the current pick results mode.

Access functions:

PickResultMode | pickResultMode() const
void | setPickResultMode(PickResultMode pickResultMode)

Notifier signal:

void | pickResultModeChanged(QPickingSettings::PickResultMode pickResult)

## Member Function Documentation

### QPickingSettings::QPickingSettings(Qt3DCore::QNode *parent = nullptr)

Default constructs an instance of QPickingSettings.

### FaceOrientationPickingMode QPickingSettings::faceOrientationPickingMode() const

Returns the back facing picking flag

Note: Getter function for property faceOrientationPickingMode.

See also setFaceOrientationPickingMode().

### `[slot]` void QPickingSettings::setFaceOrientationPickingMode(FaceOrientationPickingMode faceOrientationPickingMode)

Sets whether back facing faces are picked or not faceOrientationPickingMode

Note: Setter function for property faceOrientationPickingMode.

See also faceOrientationPickingMode().