a prism is a 3D object, basically a polygon in some plane with some extent in the plane normal direction. More...
|prism_base_t (void) throw ()|
|void||clear (void) throw ()|
|bool||isValid (void) const throw ()|
|void||setVertexCount (int N)|
a prism is a 3D object, basically a polygon in some plane with some extent in the plane normal direction.
See wikipedia for the general definition: http://en.wikipedia.org/wiki/Prism_(geometry) In particular, this is a right prism. This class (prism_base_t) is templated, so that the client can decide the max size of the vertex array. Given a polygonal base of N points, you will need 2N vertices. The array of points has a specific convention: point[2 * i] is the vertex on the "floor" (y = 0) point[(2 * i) + 1] is the vertex on the ceiling (y = height above the point[2 * i] vertex) So for instance, any consecutive sequence of 4 points starting with even index is guaranteed to be a planar rectangle. This is a very helpful property of prisms. WARNING: the xz-plane, y-extent convention is recommended for basic prisms. However, prisms can be transformed by arbitrary 3D transformations (see matrix4_t). So you can't assume that an odd-indexed point is only translated in the y-direction from its even-indexed base, for instance. However, consecutive sequences of 4 points starting with even index will always be a planar rectangle, even when transformed.
|void prism_base_t< Size >::clear||(||void||)|| throw ()
|bool prism_base_t< Size >::isValid||(||void||)|| const throw ()
|void prism_base_t< Size >::setVertexCount||(||int||N||)||