Workspace 6.21.5
|
Defines a region in 3D space which is to be used for clipping models in a scene. More...
#include <Rendering/SceneComponents/Models/clipregion.h>
Public Types | |
enum | ClipCriteria { InsideRegion , OutsideRegion } |
Public Member Functions | |
ClipRegion (const ClipRegion &clipRegion) | |
ClipRegion (const QString &id="") | |
~ClipRegion () override | |
ClipRegion * | clone () const override |
ClipCriteria | getClipCriteria () const |
Mesh::TransformMatrix | getMatrixGlobal () const override |
const Mesh::Region & | getRegion () const |
const Mesh::TransformMatrix & | getTransformMatrix () const |
bool | getVisible () const |
ClipRegion & | operator= (const ClipRegion &rhs) |
void | setClipCriteria (ClipCriteria criteria) |
void | setRegion (const Mesh::Region ®ion) |
void | setTransformMatrix (const Mesh::TransformMatrix &transformMatrix) |
void | setVisible (bool b) |
void | updateGlobalMatrix () override |
bool | visit (SceneProcessor &processor) override |
Public Member Functions inherited from SceneItem | |
~SceneItem () override | |
SceneItem * | clone () const override=0 |
bool | getEnabled () const |
const QString & | getId () const |
const Mesh::BoundingBoxMinimal & | getLocalBoundingBox () const |
virtual Mesh::TransformMatrix | getMatrixGlobal () const |
virtual Mesh::TransformMatrix | getMatrixLocal () const |
const QString & | getName () const |
Mesh::TransformMatrix | getParentMatrixGlobal () const |
Transform * | getParentTransform () |
void | setEnabled (bool b) |
void | setId (const QString &itemId) |
virtual void | setLocalBoundingBox (const Mesh::BoundingBoxMinimal &bb) |
void | setName (const QString &name) |
virtual Transform * | toTransform () |
virtual const Transform * | toTransform () const |
virtual void | updateGlobalMatrix () |
virtual bool | visit (SceneProcessor &processor)=0 |
Public Member Functions inherited from Observable | |
virtual | ~Observable () |
void | attachObserver (Observer &observer) |
void | destroy () |
void | detachObserver (Observer &observer) |
void | notifyEvent (const ObservableEvent &event) |
Public Member Functions inherited from Clonable | |
virtual | ~Clonable ()=default |
virtual Clonable * | clone () const =0 |
Additional Inherited Members | |
Protected Member Functions inherited from SceneItem | |
SceneItem (const QString &id) | |
SceneItem (const SceneItem &item) | |
virtual void | addToScene (Scene &scene, const QString &opIdPath="") |
bool | isTransformModified () const |
SceneItem & | operator= (const SceneItem &item) |
void | setTransformModified (bool b) |
Protected Member Functions inherited from Observable | |
Observable () | |
Observable (const Observable &) | |
ClipRegions are a type of SceneItem which specify a region in 3D space which is to be used for render-time clipping of MeshModelInstances in a scene. MeshModelInstances affected by ClipRegions are rendered such that parts of the instance that are inside / outside (depending upon the selected criteria) are not drawn (i.e. clipped).
ClipRegions affect all MeshModelInstances at the same level or below them in the scene graph, i.e. all MeshModelInstances under the same transform as a ClipRegion, or a child transform, will be tested against the ClipRegion.
enum ClipCriteria |
ClipRegion | ( | const QString & | id = "" | ) |
Constructs a new ClipRegion with default values. By default, the ClipRegion is defined with a "null" region, that is, a region that will not result on any clipping being performed.
ClipRegion | ( | const ClipRegion & | clipRegion | ) |
|
override |
|
overridevirtual |
ClipRegion::ClipCriteria getClipCriteria | ( | ) | const |
|
overridevirtual |
Reimplemented from SceneItem.
const Region & getRegion | ( | ) | const |
const Mesh::TransformMatrix & getTransformMatrix | ( | ) | const |
bool getVisible | ( | ) | const |
ClipRegion & operator= | ( | const ClipRegion & | rhs | ) |
rhs | The ClipRegion whose details we are assigning to this clip region. |
Assigns the specified ClipRegion to this ClipRegion, performing a deep copy of all relevant information.
void setClipCriteria | ( | ClipRegion::ClipCriteria | criteria | ) |
criteria | The criteria used to define the clip region. Inside will clip all geometry inside the clip region, Outside will clip all geometry ouside. |
void setRegion | ( | const Mesh::Region & | region | ) |
region | The region the is to be tested against for clipping. |
void setTransformMatrix | ( | const Mesh::TransformMatrix & | transformMatrix | ) |
transformMatrix | Transforms the ClipRegion using the 4x4 matrix. |
void setVisible | ( | bool | b | ) |
b | Whether or not the clip region should be visible when its scene is being visualised. |
|
overridevirtual |
Reimplemented from SceneItem.
|
overridevirtual |
processor | The SceneProcessor that the ClipRegion is to visit. |
Implements SceneItem.