VoxelSpaceNode(position, texture, heightmap, height_scale, rotation, layer)
Node that gets rendered in a semi-3D fashion. See https://github.com/s-macke/VoxelSpace. If a camera is at 0,0,0 with rotation 0,0,0 and a voxelspace node is at 0,0,0 with rotation 0,0,0, the camera will be at a corner of the node where forward is following the node in the +x-axis direction and right is following the node in the +y-axis direction. If the voxelspace y-axis scale is set to 25 then full white pixels will be at 25 in height in world space as long as voxelsapce node's position is 0,0,0. Currently, camera the x-axis rotation is pitch (clamped and mapped to -90 or -pi/2 (ground) to 90 or pi/2 (sky)), y-axis rotation is yaw, and the z-axis rotation is a fake roll.
Parameters:
position
[value: Vector3, type: Vector3]
texture
[value: TextureResource, type: TextureResource]
heightmap
[value: TextureResource, type: TextureResource]
height_scale
[value: any, type: float]
rotation
[value: Vector3, type: Vector3]
layer
[value: 0 ~ 127, type: int]
Attributes:
add_child(child)
[returns: None
]
get_child(index)
[returns: Node
]
get_child_count()
[returns: 0 or positive integer
]
mark_destroy()
[returns: None
]
mark_destroy_all()
[returns: None
]
mark_destroy_children()
[returns: None
]
remove_child(child)
[returns: None
]
tick(self, dt)
[returns: None
]
get_abs_height(x, y)
[returns: float or None
]
position
[value: Vector3, type: Vector3]
texture
[value: TextureResource, type: TextureResource]
heightmap
[value: TextureResource, type: TextureResource]
rotation
[value: Vector3, type: Vector3]
scale
[value: any (x-axis makes terrain wider (default: 1.0), y-axis makes terrain taller/shorter (default: 10.0, this means the min height will be 0.0 and the max 10.0 if the node position is 0,0,0), and z-axis makes terrain longer (default: 1.0)), type: Vector3]
repeat
[value: True or False (if True, repeats the terrain forever in all directions, default: False), type: boolean]
flip
[value: True or False (flips drawing upsidedown if True and normal if False (default)), type: boolean]
lod
[value: any (stand for Level Of Detail and affects the quality/number of samples as the view is rendered at further and further distances, default: 0.0085), type: float]
curvature
[value: any (radians, defines how much the terrain curves as the render distance increases, default: 0.0), type: float]
thickness
[value: any (defines how thick the terrain should look if you can see its sides, default: 128.0), type: float]
layer
[value: 0 ~ 127, type: int]
Overrides:
tick(self, dt)
[returns: None
] [value: function, type: function]
file: src/nodes/3D/voxelspace_node.c
landing