CSGPolygon
Extrudes a 2D polygon shape to create a 3D mesh.
This node takes a 2D polygon shape and extrudes it to create a 3D mesh.
enum Mode:
- MODE_DEPTH = 0 —- Shape is extruded to .
- MODE_SPIN = 1 —- Shape is extruded by rotating it around an axis.
- MODE_PATH = 2 —- Shape is extruded along a path set by a Shape set in .
enum PathRotation:
- PATH_ROTATION_PATH = 1 —- Slice is rotated around the up vector of the path.
- PATH_ROTATION_PATH_FOLLOW = 2 —- Slice is rotate to match the path exactly.
- float depth
Default | |
Setter | set_depth(value) |
Getter | get_depth() |
Extrusion depth when is MODE_DEPTH.
- material
Setter | set_material(value) |
Getter | get_material() |
- Mode mode
Default | 0 |
Setter | set_mode(value) |
Getter | get_mode() |
Extrusion mode.
- path_continuous_u
If true
the u component of our uv will continuously increase in unison with the distance traveled along our path when mode is .
- float path_interval
Setter | set_path_interval(value) |
Getter | get_path_interval() |
Interval at which a new extrusion slice is added along the path when is MODE_PATH.
Setter | set_path_joined(value) |
Getter | is_path_joined() |
If true
the start and end of our path are joined together ensuring there is no seam when is MODE_PATH.
- path_local
Setter | set_path_local(value) |
Getter | is_path_local() |
If we extrude centered on our path, if true
we extrude in relation to the position of our CSGPolygon when mode is .
- NodePath path_node
- path_rotation
Setter | set_path_rotation(value) |
Getter | get_path_rotation() |
The method by which each slice is rotated along the path when mode is .
- PoolVector2Array polygon
Default | PoolVector2Array( 0, 0, 0, 1, 1, 1, 1, 0 ) |
Setter | set_polygon(value) |
Getter | get_polygon() |
Point array that defines the shape that we’ll extrude.
- smooth_faces
Default | false |
Setter | set_smooth_faces(value) |
Getter | get_smooth_faces() |
Generates smooth normals so smooth shading is applied to our mesh.
- float spin_degrees
Degrees to rotate our extrusion for each slice when is MODE_SPIN.
- spin_sides
Setter | set_spin_sides(value) |
Getter | get_spin_sides() |
Number of extrusion when mode is .