RiBBox

Bounding Box for 3D objects.

[ Ray | Source | Search | Keywords | Summary | Ancestors | All Members | Descendants ]

Quick Index

DESCRIPTION
THEORY

Class Summary

class RiBBox
{
public:
RiBBox();
RiBBox(RiInterval x, RiInterval y, RiInterval z);
RiBBox(RiRayObject *obj);
RiReal GetArea();
RiBBox operator|(const RiBBox &) const;
const RiBBox &operator|==(const RiBBox &);
const RiBBox &operator&=(const RiBBox &);
bool Intersect(RiReal bmin, RiReal bmax, RiReal *num, RiReal *den) const;
bool IntersectPPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
RiInterval GetSlab(int i) const;
RiInterval GetMinMax(const RiUnitVector3 &dir) const ;
protected:
}; // RiBBox


DESCRIPTION

Currently an axis aligned bounding box. This class stores nothing, it just represents a region of space.


THEORY

from Arvo & Kirk Survey of Ray Tracing Acceleration (in Glassners Ray Tracing Book) based on the Goldsmith and Salmon article

       IC(A) = Sum( EC(Bi) + (Area(Bi) / Area(A)) * IC(Bi) )
       IC(A) = Sum( EC(Bi) ) + (1 / Area(A)) * Sum( Area(Bi) * IC(Bi) )
       IC(A) = Sum( EC(Bi) ) + (1 / Area(A)) * Sum( AIC(Bi) )
       IC(A) = sum_EC  + (1 / Area(A)) * sum_AIC

       AIC(A) = Area(A) * IC(A)
       AIC(A) = Area(A) * Sum( EC(Bi) + (Area(Bi) / Area(A)) * IC(Bi) )
       AIC(A) = Area(A) * Sum( EC(Bi) ) +  Sum( Area(Bi) * IC(Bi) )
       AIC(A) = Area(A) * Sum( EC(Bi) ) + Sum( AIC(Bi) )
       AIC(A) = Area(A) * sum_EC  + sum_AIC


RiBBox();

    RiBBox();

RiBBox(RiInterval x, RiInterval y, RiInterval z);

    RiBBox(RiInterval x, RiInterval y, RiInterval z);

RiBBox(RiRayObject *obj);

    RiBBox(RiRayObject *obj);

RiReal GetArea();

    RiReal  	 	 GetArea();

RiBBox operator|(const RiBBox &) const;

    RiBBox 	 operator|(const RiBBox &) const;

const RiBBox &operator|=(const RiBBox &);

    const RiBBox &operator|=(const RiBBox &);

const RiBBox &operator&=(const RiBBox &);

    const RiBBox &operator&=(const RiBBox &);

bool Intersect(RiReal bmin, RiReal bmax, RiReal *num, RiReal *den) const;

void AddPoint(const RiVector3 &pnt); //

    bool Intersect(RiReal bmin, RiReal bmax, RiReal *num, RiReal *den) const;

bool IntersectPPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectPPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectPPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectPPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectPMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectPMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectPMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectPMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectMPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectMPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectMPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectMPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectMMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectMMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

bool IntersectMMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

    bool IntersectMMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;

RiInterval GetSlab(int i) const;

    RiInterval	GetSlab(int i) const;

RiInterval GetMinMax(const RiUnitVector3 &dir) const ;

    RiInterval  GetMinMax(const RiUnitVector3 &dir) const ;

All Members

public:
RiReal GetArea();
RiBBox operator|(const RiBBox &) const;
const RiBBox &operator|==(const RiBBox &);
const RiBBox &operator&=(const RiBBox &);
bool Intersect(RiReal bmin, RiReal bmax, RiReal *num, RiReal *den) const;
bool IntersectPPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectPMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMPP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMPM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMMP(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
bool IntersectMMM(RiReal bmin, RiReal bmax, const RiReal *num, const RiReal *den) const;
RiInterval GetSlab(int i) const;
RiInterval GetMinMax(const RiUnitVector3 &dir) const ;
protected:

Ancestors

Class does not inherit from any other class.


Descendants


Generated from source by the Cocoon utilities on Fri Feb 25 15:15:51 2000 .