API Docs for: 2.7.3
Show:

SpiralStairwayStructure Class

Module: Component
Parent Module: Wanaplan

Stairway structure for the spiral stairway.

Constructor

SpiralStairwayStructure

()

Methods

add

(
  • propertyName
  • value
)
private

Inherited from BaseStructure:

Adds an element to the collection in parameter.

Parameters:

  • propertyName String
    Name of the dictionnary.
  • value Object
    Value to distribute.

Returns:

Returns true if the value is added else returns false.

addMaterial

(
  • parent
  • mesh
  • materialItem
)
private

Inherited from StairwayStructure:

Adds a material.

Parameters:

  • parent BABYLON.Mesh
    The parent of the mesh.
  • mesh BABYLON.Mesh
    The stairway mesh.
  • materialItem wnp.StandardMaterial
    The item material.

computeSpiralPoints

() private

Computes the points of the spiral stairway.

deserialize

(
  • hybrid
)
Object

Inherited from BaseStructure:

Deserializes the object (from JSON).

Parameters:

  • hybrid Object

    JSON describing the object, built with the method serialize.

Returns:

Object:

The Structure object built from the deserialization

draw

(
  • ctx
  • _temp
)
private

Draws the spiral stairway.

Parameters:

getAvailableProperties

() Object[]

Inherited from StairwayStructure:

Gets the available properties of the object (user-customizable).

Returns:

Object[]: An array containing several properties of the object.

getElementByName

(
  • name
  • collection
)
Object private

Inherited from BaseStructure:

Gets an element of the collection by its name.

Parameters:

  • name String
    The name of the element to search.
  • collection String
    The name of the collection in which we want to search. If this parameter is not defined, the search is done in all the collection of type array.

Returns:

Object: Returns the needed element if it exists, else returns null.

getFloor

(
  • collection
)
FloorStructure

Inherited from BaseStructure:

Gets the floor referencing this object

Parameters:

  • collection String

    Collection to search within.

Returns:

FloorStructure:

The floor containing this structure, -1 if the object has not been added to any floor collection.

getHopperPoints

() BABYLON.Vector2

Inherited from StairwayStructure

Gets the point of the hopper in the upper floor, induced by the stairway.

Returns:

BABYLON.Vector2:

The points of the hopper.

getNormalAtPoint

(
  • index
)
BABYLON.Vector3 deprecated

Inherited from StairwayStructure:

Gets the normal at the given index point.

Parameters:

  • index Number
    The index of the point.

Returns:

BABYLON.Vector3: The normal at the point.

getStepBoundPoints

(
  • bottomIndex
)
BABYLON.Vector3 private

Inherited from StairwayStructure:

Returns the 4 points of the step.

Parameters:

  • bottomIndex Number
    The index of the bottom point of the step.

Returns:

BABYLON.Vector3: The four points of a step.

initialize

() private

Inherited from BaseStructure:

Method called after the loading of the component

remove

(
  • structure
)

Inherited from StairwayStructure:

Deletes the stairway.

Parameters:

serialize

() Object

Inherited from BaseStructure:

Serializes the object (to JSON)

Returns:

Object: The serialization result, null if nothing is serialized

update

()

Inherited from BaseStructure:

Generic update method, must be overridden.

updateReferences

(
  • structure
)

Inherited from BaseStructure:

Generic method for rebuilding references after the deserialization. For example : restoring the link between a PointStructure and its parent WallStructure

Parameters:

  • structure wnp.Structure

    Floor Structure to work with

Properties

bearing

Boolean

Inherited from StairwayStructure:

Has a bearing.

Default: true

diameter

Number

Inherited from StairwayStructure:

The diameter of the middle of the stairway.

Default: 6

elevation

Number

Inherited from StairwayStructure:

The elevation of the stairway.

Default: 0

have_contremarche

Boolean

Inherited from StairwayStructure:

Has a riser

Default: true

height

Number

Inherited from StairwayStructure:

Height of the stairway.

Default: 250

id

Number

Inherited from BaseStructure:

Unique ID for the structure set up automatically

limon

Number

Inherited from StairwayStructure:

Has a limon.

Default: -1

materials

Object

Inherited from StairwayStructure:

The materials of the stairway. Nested object.

name

String

Inherited from BaseStructure:

Structure name

orientation

Boolean

Inherited from StairwayStructure:

The orientation of the stairway.

Default: true

points

BABYLON.Vector3

Inherited from StairwayStructure:

The points defining the path of the stairway.

rail_a

Boolean

Inherited from StairwayStructure:

Has a rail on the 'a' side.

Default: true

rail_b

Boolean

Inherited from StairwayStructure:

Has a rail on the 'b' side.

Default: true

room

RoomStructure

Inherited from StairwayStructure:

The parent room.

stair_height

Number

Inherited from StairwayStructure:

The stair height.

Default: 20

stair_offset

Number

Inherited from StairwayStructure:

The stair offset.

Default: 3

stair_thickness

Number

Inherited from StairwayStructure:

The stair thickness.

Default: 3

stair_width

Number

Inherited from StairwayStructure:

The stair width.

Default: 25

stick_spacement

Number

Inherited from StairwayStructure:

The stick spacement.

Default: 20

type

String

Inherited from StairwayStructure:

Type of the stairway (straight or spiral).

Default: "straight"

width

Number

Inherited from StairwayStructure:

Width of the stairway.

Default: 90