TransparencyComponent
Summary
This component enables the user to better see what he is doing by making walls and roofs transparent.
Constructor
TransparencyComponent
Syntax
TransparencyComponent
(
-
core
Summary
Parameters:
-
core
CoreWanaplan.
Item Index
Methods
Properties
Methods
compute
Syntax
compute
()
private
Summary
Recompute of the component.destroy
Syntax
destroy
()
Summary
Destructor.disable
Syntax
disable
()
Summary
Disables the componentenable
Syntax
enable
()
Summary
Enables the componentgetFloor
Syntax
getFloor
(
BABYLON.Mesh
-
[structure]
Summary
Gets the 3D mesh of the floor structure in parameter (by default current floor).Parameters:
-
[structure]
FloorStructure optionalThe floor structure.
Returns:
BABYLON.Mesh:
The floor mesh in 3D.
initialize
Syntax
initialize
()
Summary
Method called when Wanaplan is initialized. You don't need to call this method manually.onContextChanged
Syntax
onContextChanged
(
-
context
Summary
Method called when the context is switched (2D -> 3D or 3D -> 2D)Parameters:
-
context
StringThe new context
startListening
Syntax
startListening
()
Summary
Calls all the event listeners.stopListening
Syntax
stopListening
()
Summary
Removes all the event listeners.switchTransparencyMode
Syntax
switchTransparencyMode
()
Summary
Toggles between opaque/transparent.
update
Syntax
update
(
-
deltaTime
Summary
Updates the dynamic part of the component.Parameters:
-
deltaTime
NumberThe time interval.
Properties
keyboardManager
Syntax
keyboardManager
wnp.KeyboardManager
Summary
Instance of the Keyboard Manager (shortcut to wanaplan.keyboardManager).structure
Syntax
structure
wnp.Structure
Summary
Instance of the structure (shortcut to wanaplan.structure).Events
wnp.engine3d.wallTransparency.off
Syntax
wnp.engine3d.wallTransparency.off
Summary
Fired when disabling wall transparency.
wnp.engine3d.wallTransparency.on
Syntax
wnp.engine3d.wallTransparency.on
Summary
Fired when enabling wall transparency.
wnp.request.switch-transparency
Syntax
wnp.request.switch-transparency
Summary
Fired when the user requests a change in wall transparency