62 for(
int i=0; i<8; ++i)
64 vec4 out = proj_matrix *
vec4(corner[i],1);
74 out.
x() = out.
x() * 0.5f + 0.5f;
75 out.
y() = out.
y() * 0.5f + 0.5f;
76 out.
z() = out.
z() * 0.5f + 0.5f;
Associates a Renderable object to an Effect and Transform.
const T_Scalar & z() const
const Renderable * lod(int lod_index) const
Returns the Renderable object representing the LOD level specifed by lod_index.
const mat4 & viewMatrix() const
Returns the Camera's view matrix (inverse of the modeling matrix).
const T_Scalar & x() const
Transform * transform()
Returns the Transform bound tho an Actor.
const T_Scalar & z() const
Vector3< T_Scalar > xyz() const
void setNull()
Sets ths AABB as null, that is, empty.
std::vector< float > mPixelRangeSet
virtual int evaluate(Actor *actor, Camera *camera)
Viewport * viewport()
The viewport bound to a camera.
Visualization Library main namespace.
void transformed(AABB &out, const mat4 &mat) const
Transforms an AABB by the given matrix and returns it into the out parameter.
The AABB class implements an axis-aligned bounding box using vl::real precision.
real width() const
Returns the width of the AABB computed as max.x - min.x.
const vec3 & maxCorner() const
Returns the corner of the AABB with the maximum x y z coordinates.
void addPoint(const vec3 &p, real radius)
Updates the AABB to contain the given point.
const T_Scalar & y() const
const T_Scalar & y() const
const vec3 & minCorner() const
Returns the corner of the AABB with the minimum x y z coordinates.
fvec3 vec3
Defined as: 'typedef fvec3 vec3'. See also VL_PIPELINE_PRECISION.
const mat4 & projectionMatrix() const
The Camera's projection matrix.
const T_Scalar & x() const
Represents a virtual camera defining, among other things, the point of view from which scenes can be ...
const AABB & boundingBox() const
Returns the bounding box of a Renderable without recomputing the bounds if dirty. ...
fvec4 vec4
Defined as: 'typedef fvec4 vec4'. See also VL_PIPELINE_PRECISION.
const T_Scalar & w() const
real height() const
Returns the height of the AABB computed as max.y - min.y.