RectF

C++
struct RectF {
  float x, y, w, h;
  struct RectI {
    int x, y, w, h;
  };
  struct Line {
    Vec3 pointonline;
    Vec3 direction;
  };
  struct Ray {
    Vec3 origin;
    Vec3 direction;
  };
  template <typename F>
struct Lineseg_tpl {
    Vec3_tpl start;
    Vec3_tpl end;
  };
  template <typename F>
struct Triangle_tpl {
    Vec3_tpl v0, v1, v2;
  };
  struct Cone {
    Vec3 mTip;
    Vec3 mDir;
    Vec3 mBase;
    float mHeight;
    float mBaseRadius;
  };
  struct AABB {
    Vec3 min;
    Vec3 max;
    enum type_reset {
      RESET
    };
    template <typename F>
struct OBB_tpl {
      Matrix33 m33;
      Vec3 h;
      Vec3 c;
    };
    struct Sphere {
      Vec3 center;
      float radius;
    };
    struct HWVSphere {
      hwvec3 center;
      simdf radius;
    };
    struct AAEllipsoid {
      Vec3 center;
      Vec3 radius_vec;
    };
    struct Ellipsoid {
      Matrix34 ExtensionPos;
    };
    template <class Num>
struct TRect_tpl {
      Vec Min, Max;
    };
    class Velocity3;
  };
};
File

Cry_Geo.h

RectF::AABB Structure
C++
struct AABB {
  Vec3 min;
  Vec3 max;
  enum type_reset {
    RESET
  };
  template <typename F>
struct OBB_tpl {
    Matrix33 m33;
    Vec3 h;
    Vec3 c;
  };
  struct Sphere {
    Vec3 center;
    float radius;
  };
  struct HWVSphere {
    hwvec3 center;
    simdf radius;
  };
  struct AAEllipsoid {
    Vec3 center;
    Vec3 radius_vec;
  };
  struct Ellipsoid {
    Matrix34 ExtensionPos;
  };
  template <class Num>
struct TRect_tpl {
    Vec Min, Max;
  };
  class Velocity3;
};
File

Cry_Geo.h

Description

struct AABB

RectF::AABB::AAEllipsoid Structure
C++
struct AAEllipsoid {
  Vec3 center;
  Vec3 radius_vec;
};
File

Cry_Geo.h

Description

struct AAEllipsoid

RectF::AABB::AAEllipsoid::center Data Member
C++
Vec3 center;
RectF::AABB::AAEllipsoid::radius_vec Data Member
C++
Vec3 radius_vec;
RectF::AABB::AAEllipsoid::() Operator
C++
inline void operator ()(const Vec3 & c, const Vec3 & rv);
RectF::AABB::AAEllipsoid::~AAEllipsoid Destructor
C++
RectF::AABB::AAEllipsoid::AAEllipsoid Constructor ()
C++
inline AAEllipsoid();
inline AAEllipsoid(const Vec3 & c, const Vec3 & rv);
Description

default AAEllipsoid constructor (without initialisation)

RectF::AABB::Ellipsoid Structure
C++
struct Ellipsoid {
  Matrix34 ExtensionPos;
};
File

Cry_Geo.h

Description

struct Ellipsoid

RectF::AABB::Ellipsoid::ExtensionPos Data Member
C++
Matrix34 ExtensionPos;
RectF::AABB::Ellipsoid::() Operator
C++
inline void operator ()(const Matrix34 & ep);
RectF::AABB::Ellipsoid::~Ellipsoid Destructor
C++
RectF::AABB::Ellipsoid::Ellipsoid Constructor ()
C++
inline Ellipsoid();
inline Ellipsoid(const Matrix34 & ep);
Description

default Ellipsoid constructor (without initialisation)

RectF::AABB::HWVSphere Structure
C++
struct HWVSphere {
  hwvec3 center;
  simdf radius;
};
File

Cry_Geo.h

RectF::AABB::HWVSphere::center Data Member
C++
hwvec3 center;
RectF::AABB::HWVSphere::radius Data Member
C++
simdf radius;
RectF::AABB::HWVSphere::HWVSphere Constructor (Sphere&)
C++
HWVSphere(const Sphere& sp);
RectF::AABB::HWVSphere::HWVSphere Constructor (hwvec3 &, simdf &)
C++
HWVSphere(const hwvec3 & c, const simdf & r);
RectF::AABB::OBB_tpl Structure
C++
template <typename F>
struct OBB_tpl {
  Matrix33 m33;
  Vec3 h;
  Vec3 c;
};
File

Cry_Geo.h

Description

struct OBB

RectF::AABB::OBB_tpl::c Data Member
C++
Vec3 c;
Description

center of obb

RectF::AABB::OBB_tpl::h Data Member
C++
Vec3 h;
Description

half-length-vector

RectF::AABB::OBB_tpl::m33 Data Member
C++
Matrix33 m33;
Description

orientation vectors

RectF::AABB::OBB_tpl::~OBB_tpl Destructor
C++
RectF::AABB::OBB_tpl::CreateOBB Method
C++
static OBB_tpl CreateOBB(const Matrix33& m33, const Vec3& hlv, const Vec3& center);
RectF::AABB::OBB_tpl::CreateOBBfromAABB Method (Matrix33&, AABB&)
C++
static OBB_tpl CreateOBBfromAABB(const Matrix33& m33, const AABB& aabb);
RectF::AABB::OBB_tpl::CreateOBBfromAABB Method (Quat&, AABB&)
C++
static OBB_tpl CreateOBBfromAABB(const Quat& q, const AABB& aabb);
RectF::AABB::OBB_tpl::OBB_tpl Constructor
C++
inline OBB_tpl();
Description

default OBB constructor (without initialisation)

RectF::AABB::OBB_tpl::SetOBB Method
C++
void SetOBB(const Matrix33& matrix, const Vec3& hlv, const Vec3& center);
RectF::AABB::OBB_tpl::SetOBBfromAABB Method (Matrix33&, AABB&)
C++
void SetOBBfromAABB(const Matrix33& mat33, const AABB& aabb);
RectF::AABB::OBB_tpl::SetOBBfromAABB Method (Quat&, AABB&)
C++
void SetOBBfromAABB(const Quat& q, const AABB& aabb);
RectF::AABB::Sphere Structure
C++
struct Sphere {
  Vec3 center;
  float radius;
};
File

Cry_Geo.h

Description

struct Sphere

RectF::AABB::Sphere::center Data Member
C++
Vec3 center;
RectF::AABB::Sphere::radius Data Member
C++
float radius;
RectF::AABB::Sphere::() Operator
C++
void operator ()(const Vec3& c, float r);
RectF::AABB::Sphere::Sphere Constructor ()
C++
Sphere();
RectF::AABB::Sphere::Sphere Constructor (Vec3&, float)
C++
Sphere(const Vec3& c, float r);
RectF::AABB::TRect_tpl Structure
C++
template <class Num>
struct TRect_tpl {
  Vec Min, Max;
};
File

Cry_Geo.h

Description

struct TRect

RectF::AABB::TRect_tpl::Max Data Member
C++
Vec Max;
RectF::AABB::TRect_tpl::Min Data Member
C++
Vec Min;
RectF::AABB::TRect_tpl::* Operator
C++
inline TRect_tpl operator *(Num k) const;
RectF::AABB::TRect_tpl::/ Operator
C++
inline TRect_tpl operator /(Num k) const;
RectF::AABB::TRect_tpl::DoIntersect Method
C++
inline TRect_tpl & DoIntersect(const TRect_tpl & rc);
RectF::AABB::TRect_tpl::DoUnite Method
C++
inline TRect_tpl & DoUnite(const TRect_tpl & rc);
RectF::AABB::TRect_tpl::GetDim Method
C++
inline Vec GetDim() const;
RectF::AABB::TRect_tpl::GetHeight Method
C++
inline Num GetHeight() const;
RectF::AABB::TRect_tpl::GetSubRect Method
C++
inline TRect_tpl GetSubRect(const TRect_tpl & rc) const;
RectF::AABB::TRect_tpl::GetSubRectInv Method
C++
inline TRect_tpl GetSubRectInv(const TRect_tpl & rcSub) const;
RectF::AABB::TRect_tpl::GetWidth Method
C++
inline Num GetWidth() const;
RectF::AABB::TRect_tpl::InRect Method (TRect_tpl &)
C++
inline bool InRect(const TRect_tpl & rc) const;
RectF::AABB::TRect_tpl::InRect Method (Vec)
C++
inline bool InRect(Vec pt) const;
RectF::AABB::TRect_tpl::Intersects Method
C++
inline bool Intersects(const TRect_tpl & rc) const;
RectF::AABB::TRect_tpl::IntoRect Method
C++
inline Vec & IntoRect(Vec & pt) const;
RectF::AABB::TRect_tpl::IsEmpty Method
C++
inline bool IsEmpty() const;
RectF::AABB::TRect_tpl::IsEqual Method
C++
inline bool IsEqual(const TRect_tpl & rc) const;
RectF::AABB::TRect_tpl::SetEmpty Method
C++
inline TRect_tpl & SetEmpty();
RectF::AABB::TRect_tpl::TRect_tpl Constructor ()
C++
inline TRect_tpl();
RectF::AABB::TRect_tpl::TRect_tpl Constructor (Num, Num, Num, Num)
C++
inline TRect_tpl(Num x1, Num y1, Num x2, Num y2);
RectF::AABB::TRect_tpl::TRect_tpl Constructor (TRect_tpl &)
C++
inline TRect_tpl(const TRect_tpl & rc);
RectF::AABB::TRect_tpl::TRect_tpl Constructor (Vec&, Vec&)
C++
inline TRect_tpl(const Vec& min, const Vec& max);
RectF::AABB::TRect_tpl::Vec Nested Type
C++
typedef Vec2_tpl Vec;
RectF::AABB::type_reset Enumeration
C++
enum type_reset {
  RESET
};
File

Cry_Geo.h

RectF::AABB::Velocity3 Class
Class Hierarchy
C++
class Velocity3;
File

Cry_Geo.h

Description

Manage linear and rotational 3D velocity in a class

RectF::AABB::Velocity3::vLin Data Member
C++
Vec3 vLin;
RectF::AABB::Velocity3::vRot Data Member
C++
Vec3 vRot;
RectF::AABB::Velocity3::*= Operator
C++
void operator *=(float f);
RectF::AABB::Velocity3::+= Operator
C++
void operator +=(Velocity3 const& vv);
RectF::AABB::Velocity3::FromDelta Method
C++
void FromDelta(QuatT const& loc0, QuatT const& loc1, float fTime);
RectF::AABB::Velocity3::Interp Method
C++
void Interp(Velocity3 const& vv, float f);
RectF::AABB::Velocity3::Velocity3 Constructor ()
C++
Velocity3();
RectF::AABB::Velocity3::Velocity3 Constructor (Vec3 const&)
C++
Velocity3(Vec3 const& vLin);
RectF::AABB::Velocity3::Velocity3 Constructor (Vec3 const&, Vec3 const&)
C++
Velocity3(Vec3 const& vLin, Vec3 const& vRot);
RectF::AABB::Velocity3::Velocity3 Constructor (type_zero)
C++
Velocity3(type_zero);
RectF::AABB::Velocity3::VelocityAt Method
C++
Vec3 VelocityAt(Vec3 const& vPosRel) const;
RectF::AABB::max Data Member
C++
Vec3 max;
RectF::AABB::min Data Member
C++
Vec3 min;
RectF::AABB::AABB Constructor ()
C++
AABB();
explicit AABB(float radius);
explicit AABB(const Vec3& v);
AABB(const Vec3& v, float radius);
AABB(const Vec3 & vmin, const Vec3 & vmax);
AABB(const AABB & aabb);
inline AABB(const Vec3* points, int num);
Description

default AABB constructor (without initialisation)

RectF::AABB::AABB Constructor (type_reset)
C++
AABB(type_reset);
Description

AABB aabb(RESET) generates a reset aabb

RectF::AABB::Add Method (AABB&)
C++
void Add(const AABB& bb);
RectF::AABB::Add Method (Vec3 &)
C++
void Add(const Vec3 & v);
RectF::AABB::Add Method (Vec3&, float)
C++
inline void Add(const Vec3& v, float radius);
RectF::AABB::AddToBounds Method
C++
inline void AddToBounds(const Vec3& v, Vec3& mins, Vec3& maxs);
RectF::AABB::Augment Method
C++
inline void Augment(AABB const& bb);
Description

Augment the box on all sides by a box.

RectF::AABB::CalcArea Method
C++
inline float CalcArea(const Vec3 * vertices, int numvertices, const Vec3 & normal);
Description

! calc the area of a polygon giving a list of vertices and normal

RectF::AABB::ClipMoveToBox Method
C++
void ClipMoveToBox(AABB const& bb);
RectF::AABB::ClipToBox Method
C++
void ClipToBox(AABB const& bb);
RectF::AABB::ContainsBox Method
C++
bool ContainsBox(AABB const& b) const;
RectF::AABB::ContainsBox2D Method
C++
bool ContainsBox2D(AABB const& b) const;
RectF::AABB::CreateAABBfromCone Method
C++
static AABB CreateAABBfromCone(const Cone& c);
Description

Converts a Cone into a tight fitting AABB

RectF::AABB::CreateAABBfromOBB Method (OBB_tpl&)
C++
template <typename F> static AABB CreateAABBfromOBB(const OBB_tpl& obb);
RectF::AABB::CreateAABBfromOBB Method (Vec3&, OBB_tpl&, f32)
C++
template <typename F> static AABB CreateAABBfromOBB(const Vec3& wpos, const OBB_tpl& obb, f32 scaling = 1.0f);
RectF::AABB::CreateTransformedAABB Method (Matrix34&, AABB&)
C++
static AABB CreateTransformedAABB(const Matrix34& m34, const AABB& aabb);
RectF::AABB::CreateTransformedAABB Method (QuatT&, AABB&)
C++
static AABB CreateTransformedAABB(const QuatT& qt, const AABB& aabb);
RectF::AABB::Expand Method
C++
inline void Expand(Vec3 const& v);
RectF::AABB::GetCenter Method
C++
Vec3 GetCenter() const;
RectF::AABB::GetDistance Method
C++
float GetDistance(Vec3 const& v) const;
RectF::AABB::GetDistanceSqr Method
C++
float GetDistanceSqr(Vec3 const& v) const;
RectF::AABB::GetRadius Method
C++
float GetRadius() const;
RectF::AABB::GetRadiusSqr Method
C++
float GetRadiusSqr() const;
RectF::AABB::GetSize Method
C++
Vec3 GetSize() const;
RectF::AABB::GetVolume Method
C++
float GetVolume() const;
RectF::AABB::IsContainPoint Method
C++
bool IsContainPoint(const Vec3 & pos) const;
Description

! Check if this bounding box contains a point within itself.

RectF::AABB::IsContainSphere Method
C++
bool IsContainSphere(const Vec3 & pos, float radius) const;
Description

! Check if this bounding box contain sphere within itself.

RectF::AABB::IsEmpty Method
C++
bool IsEmpty() const;
Description

! Check if bounding box is empty (Zero volume).

RectF::AABB::IsEquivalent Method
C++
bool IsEquivalent(const AABB& a, const AABB& b, float epsilon = VEC_EPSILON);
RectF::AABB::IsIntersectBox Method
C++
inline bool IsIntersectBox(const AABB & b) const;
Description

Check two bounding boxes for intersection.

RectF::AABB::IsMaxBB Method
C++
inline bool IsMaxBB(const Vec3& v);
Description

! checks if this has been set to maxBB

RectF::AABB::IsMinBB Method
C++
inline bool IsMinBB(const Vec3& v);
Description

! checks if this has been set to minBB

RectF::AABB::IsNonZero Method
C++
bool IsNonZero() const;
Description

! Check if bounding box has valid, non zero volume

RectF::AABB::IsOverlapSphereBounds Method
C++
bool IsOverlapSphereBounds(const Vec3 & pos, float radius) const;
Description

! Check if this bounding box overlap with bounding box of sphere.

RectF::AABB::IsReset Method
C++
bool IsReset() const;
RectF::AABB::IsResetSel Method
C++
float IsResetSel(float ifReset, float ifNotReset) const;
RectF::AABB::Move Method
C++
inline void Move(const Vec3& v);
RectF::AABB::Reset Method
C++
void Reset();
Description

! Reset Bounding box before calculating bounds. ! These values ensure that Add() functions work correctly for Reset bbs, without additional comparisons.

RectF::AABB::SetAABBfromOBB Method (OBB_tpl&)
C++
template <typename F> void SetAABBfromOBB(const OBB_tpl& obb);
Description

create an AABB using just the extensions of the OBB and ignore the orientation.

RectF::AABB::SetAABBfromOBB Method (Vec3&, OBB_tpl&, f32)
C++
template <typename F> void SetAABBfromOBB(const Vec3& wpos, const OBB_tpl& obb, f32 scaling = 1.0f);
Description

!

  • converts an OBB into an tight fitting AABB

*

*

  • return values:
  • expanded AABB in world-space
RectF::AABB::SetMaxBB Method
C++
inline Vec3 SetMaxBB();
RectF::AABB::SetMinBB Method
C++
inline Vec3 SetMinBB();
RectF::AABB::SetTransformedAABB Method (Matrix34&, AABB&)
C++
void SetTransformedAABB(const Matrix34& m34, const AABB& aabb);
Description

!

  • calculate the new bounds of a transformed AABB

*

*

  • return values:
  • expanded AABB in world-space
RectF::AABB::SetTransformedAABB Method (QuatT&, AABB&)
C++
void SetTransformedAABB(const QuatT& qt, const AABB& aabb);
RectF::AABB::OBB Nested Type
C++
typedef OBB_tpl OBB;
RectF::AABB::Rectf Nested Type
C++
typedef TRect_tpl<float> Rectf;
RectF::AABB::Recti Nested Type
C++
typedef TRect_tpl<int> Recti;
RectF::AABB::Triangle Nested Type
C++
typedef Triangle_tpl Triangle;
RectF::AABB::Triangle_f64 Nested Type
C++
typedef Triangle_tpl Triangle_f64;
RectF::Cone Structure
C++
struct Cone {
  Vec3 mTip;
  Vec3 mDir;
  Vec3 mBase;
  float mHeight;
  float mBaseRadius;
};
File

Cry_Geo.h

Description

struct Cone

RectF::Cone::mBase Data Member
C++
Vec3 mBase;
RectF::Cone::mBaseRadius Data Member
C++
float mBaseRadius;
RectF::Cone::mDir Data Member
C++
Vec3 mDir;
RectF::Cone::mHeight Data Member
C++
float mHeight;
RectF::Cone::mTip Data Member
C++
Vec3 mTip;
RectF::Cone::Cone Constructor ()
C++
Cone();
RectF::Cone::Cone Constructor (Vec3&, Vec3&, float, float)
C++
Cone(const Vec3& tip, const Vec3& dir, float height, float baseRadius);
RectF::Line Structure
C++
struct Line {
  Vec3 pointonline;
  Vec3 direction;
};
File

Cry_Geo.h

Description

struct Line

RectF::Line::direction Data Member
C++
Vec3 direction;
Description

caution: the direction is important for any intersection test

RectF::Line::pointonline Data Member
C++
Vec3 pointonline;
RectF::Line::() Operator
C++
inline void operator ()(const Vec3 & o, const Vec3 & d);
RectF::Line::~Line Destructor
C++
~Line();
RectF::Line::Line Constructor ()
C++
inline Line();
inline Line(const Vec3 & o, const Vec3 & d);
Description

default Line constructor (without initialisation)

RectF::Lineseg_tpl Structure
C++
template <typename F>
struct Lineseg_tpl {
  Vec3_tpl start;
  Vec3_tpl end;
};
File

Cry_Geo.h

Description

struct Lineseg

RectF::Lineseg_tpl::end Data Member
C++
RectF::Lineseg_tpl::start Data Member
C++
Vec3_tpl start;
RectF::Lineseg_tpl::() Operator
C++
inline void operator ()(const Vec3_tpl & s, const Vec3_tpl & e);
RectF::Lineseg_tpl::~Lineseg_tpl Destructor
C++
RectF::Lineseg_tpl::GetPoint Method
C++
Vec3 GetPoint(F t) const;
RectF::Lineseg_tpl::Lineseg_tpl Constructor ()
C++
inline Lineseg_tpl();
inline Lineseg_tpl(const Vec3_tpl & s, const Vec3_tpl & e);
Description

default Lineseg constructor (without initialisation)

RectF::Ray Structure
C++
struct Ray {
  Vec3 origin;
  Vec3 direction;
};
File

Cry_Geo.h

Description

struct Ray

RectF::Ray::direction Data Member
C++
Vec3 direction;
RectF::Ray::origin Data Member
C++
Vec3 origin;
RectF::Ray::() Operator
C++
inline void operator ()(const Vec3 & o, const Vec3 & d);
RectF::Ray::~Ray Destructor
C++
~Ray();
RectF::Ray::Ray Constructor ()
C++
inline Ray();
inline Ray(const Vec3 & o, const Vec3 & d);
Description

default Ray constructor (without initialisation)

RectF::RectI Structure
C++
struct RectI {
  int x, y, w, h;
};
File

Cry_Geo.h

RectF::RectI::h Data Member
C++
int h;
RectF::RectI::w Data Member
C++
int w;
RectF::RectI::x Data Member
C++
int x;
RectF::RectI::y Data Member
C++
int y;
RectF::RectI::Add Method (RectI)
C++
_inline void Add(RectI rcAdd);
RectF::RectI::Add Method (int, int, int, int)
C++
_inline void Add(int inX, int inY, int inW, int inH);
RectF::RectI::RectI Constructor ()
C++
RectI();
RectF::RectI::RectI Constructor (int, int, int, int)
C++
RectI(int inX, int inY, int inW, int inH);
RectF::Triangle_tpl Structure
C++
template <typename F>
struct Triangle_tpl {
  Vec3_tpl v0, v1, v2;
};
File

Cry_Geo.h

Description

struct Triangle

RectF::Triangle_tpl::v0 Data Member
C++
RectF::Triangle_tpl::v1 Data Member
C++
RectF::Triangle_tpl::v2 Data Member
C++
RectF::Triangle_tpl::() Operator
C++
void operator ()(const Vec3_tpl& a, const Vec3_tpl& b, const Vec3_tpl& c);
RectF::Triangle_tpl::~Triangle_tpl Destructor
C++
RectF::Triangle_tpl::GetArea Method
C++
F GetArea() const;
RectF::Triangle_tpl::GetNormal Method
C++
Vec3_tpl GetNormal() const;
RectF::Triangle_tpl::Triangle_tpl Constructor ()
C++
Triangle_tpl();
Triangle_tpl(const Vec3_tpl& a, const Vec3_tpl& b, const Vec3_tpl& c);
Description

default Lineseg constructor (without initialisation)

RectF::h Data Member
C++
float h;
RectF::w Data Member
C++
float w;
RectF::x Data Member
C++
float x;
RectF::y Data Member
C++
float y;
RectF::RectF Constructor
C++
RectF();
RectF::Lineseg Nested Type
C++
typedef Lineseg_tpl<float> Lineseg;
RectF::Linesegr Nested Type
C++
typedef Lineseg_tpl Linesegr;