Interface IBoundingBoxGizmo
Hierarchy
- IGizmo
- IBoundingBoxGizmo
Implemented by
Index
Properties
- _root
Mesh - attached
Mesh - attached
Node - axis
Factor - custom
Rotation Quaternion - fixed
Drag Mesh Bounds Size - fixed
Drag Mesh Screen Size - fixed
Drag Mesh Screen Size Distance Factor - gizmo
Layer - ignore
Children - include
Child Predicate - is
Hovered - on
Drag Start Observable - on
Rotation Sphere Drag End Observable - on
Rotation Sphere Drag Observable - on
Scale Box Drag End Observable - on
Scale Box Drag Observable - rotation
Sphere Size - scale
Box Size - scale
Drag Speed - scale
Pivot - scale
Ratio - update
Gizmo Position To Match Attached Mesh - update
Gizmo Rotation To Match Attached Mesh - update
Scale
Methods
Properties
_root MeshSearch playground for _rootMesh
The root mesh of the gizmo
attached MeshSearch playground for attachedMesh
Mesh that the gizmo will be attached to. (eg. on a drag gizmo the mesh that will be dragged)
- When set, interactions will be enabled
attached NodeSearch playground for attachedNode
Node that the gizmo will be attached to. (eg. on a drag gizmo the mesh, bone or NodeTransform that will be dragged)
- When set, interactions will be enabled
axis FactorSearch playground for axisFactor
Scale factor vector used for masking some axis
custom Rotation QuaternionSearch playground for customRotationQuaternion
posture that the gizmo will be display When set null, default value will be used (Quaternion(0, 0, 0, 1))
fixed Drag Mesh Bounds SizeSearch playground for fixedDragMeshBoundsSize
If set, the rotation spheres and scale boxes will increase in size based on the size of the bounding box Note : fixedDragMeshScreenSize takes precedence over fixedDragMeshBoundsSize if both are true
fixed Drag Mesh Screen SizeSearch playground for fixedDragMeshScreenSize
If set, the rotation spheres and scale boxes will increase in size based on the distance away from the camera to have a consistent screen size Note : fixedDragMeshScreenSize takes precedence over fixedDragMeshBoundsSize if both are true
fixed Drag Mesh Screen Size Distance FactorSearch playground for fixedDragMeshScreenSizeDistanceFactor
The distance away from the object which the draggable meshes should appear world sized when fixedDragMeshScreenSize is set to true
gizmo LayerSearch playground for gizmoLayer
The utility layer the gizmo will be added to
ignore ChildrenSearch playground for ignoreChildren
If child meshes should be ignored when calculating the bounding box. This should be set to true to avoid perf hits with heavily nested meshes.
include Child PredicateSearch playground for includeChildPredicate
Returns true if a descendant should be included when computing the bounding box. When null, all descendants are included. If ignoreChildren is set this will be ignored.
Readonly is HoveredSearch playground for isHovered
True when the mouse pointer is hovered a gizmo mesh
on Drag Start ObservableSearch playground for onDragStartObservable
Fired when a rotation sphere or scale box is dragged
on Rotation Sphere Drag End ObservableSearch playground for onRotationSphereDragEndObservable
Fired when a rotation sphere drag is ended
on Rotation Sphere Drag ObservableSearch playground for onRotationSphereDragObservable
Fired when a rotation sphere is dragged
on Scale Box Drag End ObservableSearch playground for onScaleBoxDragEndObservable
Fired when a scale box drag is ended
on Scale Box Drag ObservableSearch playground for onScaleBoxDragObservable
Fired when a scale box is dragged
rotation Sphere SizeSearch playground for rotationSphereSize
The size of the rotation spheres attached to the bounding box
scale Box SizeSearch playground for scaleBoxSize
The size of the scale boxes attached to the bounding box
scale Drag SpeedSearch playground for scaleDragSpeed
Scale factor scalar affecting all axes' drag speed
scale PivotSearch playground for scalePivot
Relative bounding box pivot used when scaling the attached node.
scale RatioSearch playground for scaleRatio
Ratio for the scale of the gizmo
update Gizmo Position To Match Attached MeshSearch playground for updateGizmoPositionToMatchAttachedMesh
If set the gizmo's position will be updated to match the attached mesh each frame (Default: true)
update Gizmo Rotation To Match Attached MeshSearch playground for updateGizmoRotationToMatchAttachedMesh
If set the gizmo's rotation will be updated to match the attached mesh each frame (Default: true)
update ScaleSearch playground for updateScale
When set, the gizmo will always appear the same size no matter where the camera is (default: true)
Methods
disposeSearch playground for dispose
Releases all held resources
Returns void
enable Drag BehaviorSearch playground for enableDragBehavior
Enables a pointer drag behavior on the bounding box of the gizmo
Returns void
get Scale BoxesSearch playground for getScaleBoxes
Returns an array containing all boxes used for scaling (in increasing x, y and z orders)
Returns AbstractMesh[]
set ColorSearch playground for setColor
Sets the color of the bounding box gizmo
Parameters
color: Color3
the color to set
Returns void
set Custom MeshSearch playground for setCustomMesh
Disposes and replaces the current meshes in the gizmo with the specified mesh
Parameters
mesh: Mesh
Returns void
set Enabled Rotation AxisSearch playground for setEnabledRotationAxis
Enables rotation on the specified axis and disables rotation on the others
Parameters
axis: string
The list of axis that should be enabled (eg. "xy" or "xyz")
Returns void
set Enabled ScalingSearch playground for setEnabledScaling
Enables/disables scaling
Parameters
enable: boolean
if scaling should be enabled
Optional homogeneousScaling: boolean
defines if scaling should only be homogeneous
Returns void
update Bounding BoxSearch playground for updateBoundingBox
Updates the bounding box information for the Gizmo
Returns void
Interface for bounding box gizmo