Class HandMenuSince
Hierarchy (View Summary)
- TouchHolographicMenu
- HandMenu
Index
Constructors
Properties
Accessors
Methods
Constructors
constructor
-
Creates a hand menu GUI 3D control
Parameters
- xr: WebXRExperienceHelper
the WebXRExperienceHelper used to link this control to the enabled WebXRHandTracking feature
Optionalname: stringname of the hand menu
Returns HandMenu
- xr: WebXRExperienceHelper
Properties
margin
Gets or sets the distance between elements
Optionalname
Defines the control name
on Pointer Click Observable
An event triggered when a control is clicked on (with a mouse)
on Pointer Down Observable
An event triggered when the pointer taps the control
on Pointer Enter Observable
An event triggered when pointer enters the control
on Pointer Move Observable
An event triggered when the pointer moves over the control
on Pointer Out Observable
An event triggered when the pointer moves out of the control
on Pointer Up Observable
An event triggered when pointer is up
parent
Gets or sets the parent container
pointer Down Animation
Callback used to start pointer down animation
pointer Enter Animation
Callback used to start pointer enter animation
pointer Out Animation
Callback used to start pointer out animation
pointer Up Animation
Callback used to start pointer up animation
Static ReadonlyFACEFORWARD_ ORIENTATION
Control will rotate to look at z axis (0, 0, 1)
Static ReadonlyFACEFORWARDREVERSED_ ORIENTATION
Control will rotate to look at negative z axis (0, 0, -1)
Static ReadonlyFACEORIGIN_ ORIENTATION
Control will rotate to make it look at sphere central axis
Static ReadonlyFACEORIGINREVERSED_ ORIENTATION
Control will rotate to make it look back at sphere central axis
Static ReadonlyUNSET_ ORIENTATION
Control rotation will remain unchanged
Accessors
back Plate Margin
-
get backPlateMargin(): number
Gets or sets the margin size of the backplate in button size units. Setting this to 1, will make the backPlate margin the size of 1 button
Returns number
-
set backPlateMargin(value: number): void
Parameters
- value: number
Returns void
behaviors
-
Gets the list of attached behaviors
Returns Behavior<Control3D>[]
block Layout
-
get blockLayout(): boolean
Gets or sets a boolean indicating if the layout must be blocked (default is false). This is helpful to optimize layout operation when adding multiple children in a row
Returns boolean
-
set blockLayout(value: boolean): void
Parameters
- value: boolean
Returns void
children
-
Gets the list of child controls
Returns Control3D[]
columns
-
get columns(): int
Gets or sets the number of columns requested (10 by default). The panel will automatically compute the number of rows based on number of child controls.
Returns int
-
set columns(value: int): void
Parameters
- value: int
Returns void
hand Constraint Behavior
-
get handConstraintBehavior(): HandConstraintBehavior
The hand constraint behavior setting the transformation of this node
Returns HandConstraintBehavior
is Visible
-
get isVisible(): boolean
Gets or sets a boolean indicating if the control is visible
Returns boolean
-
set isVisible(value: boolean): void
Parameters
- value: boolean
Returns void
mesh
-
get mesh(): Nullable<AbstractMesh>
Gets the mesh used to render this control
Returns Nullable<AbstractMesh>
node
-
get node(): Nullable<TransformNode>
Gets the transform node used by this control
Returns Nullable<TransformNode>
orientation
-
get orientation(): number
Gets or sets the orientation to apply to all controls (BABYLON.Container3D.FaceOriginReversedOrientation by default)
Value Type Description 0 UNSET_ORIENTATION Control rotation will remain unchanged 1 FACEORIGIN_ORIENTATION Control will rotate to make it look at sphere central axis 2 FACEORIGINREVERSED_ORIENTATION Control will rotate to make it look back at sphere central axis 3 FACEFORWARD_ORIENTATION Control will rotate to look at z axis (0, 0, 1) 4 FACEFORWARDREVERSED_ORIENTATION Control will rotate to look at negative z axis (0, 0, -1) Returns number
-
set orientation(value: number): void
Parameters
- value: number
Returns void
position
-
get position(): Vector3
Gets or sets the control position in world space
Returns Vector3
-
set position(value: Vector3): void
Parameters
- value: Vector3
Returns void
rows
-
get rows(): int
Gets or sets a the number of rows requested. The panel will automatically compute the number of columns based on number of child controls.
Returns int
-
set rows(value: int): void
Parameters
- value: int
Returns void
scaling
-
get scaling(): Vector3
Gets or sets the control scaling in world space
Returns Vector3
-
set scaling(value: Vector3): void
Parameters
- value: Vector3
Returns void
type Name
-
get typeName(): string
Gets a string representing the class name
Returns string
Methods
add Behavior
add Button
-
Adds a button to the menu. Please note that the back material of the button will be set to transparent as it is attached to the menu.
Parameters
- button: TouchHolographicButton
Button to add
Returns TouchHolographicMenu
This menu
- button: TouchHolographicButton
add Control
-
This method should not be used directly. It is inherited from
Container3D. Please useaddButtoninstead.Parameters
- _control: Control3D
the control to add
Returns Container3D
the current container
- _control: Control3D
contains Control
-
Gets a boolean indicating if the given control is in the children of this control
Parameters
- control: Control3D
defines the control to check
Returns boolean
true if the control is in the child list
- control: Control3D
dispose
-
Disposes the hand menu
Returns void
get Behavior By Name
-
Gets an attached behavior by name
Parameters
- name: string
defines the name of the behavior to look for
Returns Nullable<Behavior<Control3D>>
null if behavior was not found else the requested behavior
- name: string
get Class Name
-
Get the current class name of the control.
Returns string
current class name
link To Transform Node
-
Link the control as child of the given node
Parameters
- node: Nullable<TransformNode>
defines the node to link to. Use null to unlink the control
Returns Control3D
the current control
- node: Nullable<TransformNode>
remove Behavior
remove Control
-
Removes a control from the children of this control
Parameters
- control: Control3D
defines the control to remove
Returns Container3D
the current container
- control: Control3D
update Layout
-
Force the container to update the layout. Please note that it will not take blockLayout property in account
Returns Container3D
the current container
Hand menu that displays buttons and floats around the hand. 5.0.0