BillboardEffect
-
class BillboardEffect
Bases:
RenderEffect
Indicates that geometry at this node should automatically rotate to face the camera, or any other arbitrary node.
Inheritance diagram
-
bool get_axial_rotate(void) const
Returns true if this billboard rotates only around the axis of the up vector, or false if it rotates freely in three dimensions.
-
static TypeHandle get_class_type(void)
-
bool get_eye_relative(void) const
Returns true if this billboard interprets the up vector relative to the camera, or false if it is relative to the world.
-
bool get_fixed_depth(void) const
Returns true if this billboard always appears at a fixed distance from the camera.
-
NodePath const &get_look_at(void) const
Returns the node this billboard will rotate to look towards. If this is empty, it means the billboard will rotate towards the current camera node, wherever that might be.
-
LPoint3 const &get_look_at_point(void) const
Returns the point, relative to the
look_at()
node, towards which the billboard will rotate. Normally this is (0, 0, 0).
-
PN_stdfloat get_offset(void) const
Returns the distance toward the camera (or the look_at_point) the billboard is moved towards, after rotating. This can be used to ensure the billboard is not obscured by nearby geometry.
-
bool is_off(void) const
Returns true if the
BillboardEffect
is an ‘off’BillboardEffect
, indicating that it does not enable billboarding. This kind ofBillboardEffect
isn’t particularly useful and isn’t normally created or stored in the graph; it might be implicitly discovered as the result of a NodePath::get_rel_state().
-
static ConstPointerTo<RenderEffect> make(LVector3 const &up_vector, bool eye_relative, bool axial_rotate, PN_stdfloat offset, NodePath const &look_at, LPoint3 const &look_at_point, bool fixed_depth = false)
Constructs a new
BillboardEffect
object with the indicated properties.
-
ConstPointerTo<RenderEffect> make_axis(void)
A convenience function to make a typical axis-rotating billboard.
-
ConstPointerTo<RenderEffect> make_point_eye(void)
A convenience function to make a typical eye-relative point-rotating billboard.
-
ConstPointerTo<RenderEffect> make_point_world(void)
A convenience function to make a typical world-relative point-rotating billboard.
-
bool get_axial_rotate(void) const