Sub-object for geometric objects. More...
#include <sobject.h>
Inherits dyn_collectable.
Inherited by rtl_groupmem and rtl_object.
This class is an abstract definition of the basic elements of a geometric object. All classes that are renderable should inherit from this class and implement the intersection and normal functions.
[virtual]Intersects a ray with this object. This object is the default behaviour all objects shoud call this function in their intersect routine. If the default does no return NOHIT then do not continue intersection. This function transforms the ray into object space and calls lclintersect. The bool should be true if this class is a re-hit from a csg class.
Reimplemented in rtl_triangle, rtl_soft::rtl_softvoxel, rtl_polyhedron, rtl_object and rtl_groupobj.
[pure virtual]Returns the normal at the position of the last successfull intersection calculation.
Reimplemented in rtl_triangle, rtl_soft::rtl_softvoxel and rtl_object.
[virtual]Returns true if this object intersects with the given axis aligned box. The default is true because this function is used to cull the object from a subdivision of space, true means the object will never be culled.
Reimplemented in rtl_triangle, rtl_polyhedron and rtl_object.
Return the bounding box for this object (in world space).
[virtual]Returns the material for this sub-object.
Reimplemented in rtl_triangle, rtl_polyhedron, rtl_object and rtl_groupmem.
Returns the flags for this object.
Returns the flags for this object.
[virtual]Returns the sub-object that was struck by the ray during the last call to intersect. The return of this function should only really differ from this in the case of a grouped object (rtl_groupobj). You should never need to override this function.
Reimplemented in rtl_groupobj.
[virtual]Returns the object that contains this subobject. If this object is a sub-class of rtl_groupmem then the return will not be valid, otherwise the object cannot be contained and will return 0.
Reimplemented in rtl_groupmem.
[virtual]Set the bounding box for this object (in object space). This function should not be called after an object has been added to a rtl_world object.
Reimplemented in rtl_object.
[protected]
[static]On if the illumination model should negate the normal.
[static]On if the object has a defined bounding box, off by default. All objects must have a defined bounding box if they are to be added to scenes with space subdivision.
[protected]
[protected]
Reimplemented in rtl_superellipsoid.
[protected]
[protected]
Reimplemented in rtl_object.