Methods
# Cube(x, y, z, color) → {Triangles}
Create a cubic geometric mesh.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
x |
number | ||
y |
number | ||
z |
number | ||
color |
Array.<number> | [1,1,1,1] |
Returns:
- Type
- Triangles
# Sphere(radius, facets, color)
Create a spherical geometric mesh. The mesh is an inflated, subdivided cube.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
radius |
number | ||
facets |
number | Number of subdivisions vertical and horizontal |
|
color |
Array.<number> | [1,1,1,1] |
Returns:
Triangles
# Cylinder(radius, height, facets, color)
Create a cynlindrical geometric mesh.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
radius |
number | ||
height |
number | ||
facets |
number | Number of subdivisions |
|
color |
Array.<number> | [1,1,1,1] |
Returns:
Triangles