Classes | Macros | Typedefs
OPC_OptimizedTree.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  AABBCollisionNode
 
class  AABBCollisionTree
 
class  AABBNoLeafNode
 
class  AABBNoLeafTree
 
class  AABBOptimizedTree
 
class  AABBQuantizedNode
 
class  AABBQuantizedNoLeafNode
 
class  AABBQuantizedNoLeafTree
 
class  AABBQuantizedTree
 

Macros

#define __OPC_OPTIMIZEDTREE_H__
 
#define EXWORD   udword
 
#define EXWORD   udword
 
#define IMPLEMENT_COLLISION_TREE(base_class, node)
 
#define IMPLEMENT_COLLISION_TREE(base_class, node)
 Common interface for a collision tree. More...
 
#define IMPLEMENT_IMPLICIT_NODE(base_class, volume)
 Common interface for a node of an implicit tree. More...
 
#define IMPLEMENT_IMPLICIT_NODE(base_class, volume)
 
#define IMPLEMENT_NOLEAF_NODE(base_class, volume)
 Common interface for a node of a no-leaf tree. More...
 
#define IMPLEMENT_NOLEAF_NODE(base_class, volume)
 

Typedefs

typedef bool(* GenericWalkingCallback) (const void *current, void *user_data)
 

Detailed Description

Contains code for optimized trees.

Author
Pierre Terdiman
Date
March, 20, 2001

Definition in file OPC_OptimizedTree.h.

Macro Definition Documentation

#define __OPC_OPTIMIZEDTREE_H__

Definition at line 22 of file Opcode.h.

#define EXWORD   udword

Definition at line 27 of file Opcode.h.

#define EXWORD   udword
#define IMPLEMENT_COLLISION_TREE (   base_class,
  node 
)
Value:
public: \
/* Constructor / Destructor */ \
base_class(); \
virtual ~base_class(); \
/* Builds from a standard tree */ \
override(AABBOptimizedTree) bool Build(AABBTree* tree); \
/* Refits the tree */ \
override(AABBOptimizedTree) bool Refit(const MeshInterface* mesh_interface); \
/* Walks the tree */ \
override(AABBOptimizedTree) bool Walk(GenericWalkingCallback callback, void* user_data) const; \
/* Data access */ \
inline_ const node* GetNodes() const { return mNodes; } \
/* Stats */ \
override(AABBOptimizedTree) udword GetUsedBytes() const { return mNbNodes*sizeof(node); } \
private: \
node* mNodes;
#define inline_
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65
#define override(base_class)
bool(* GenericWalkingCallback)(const void *current, void *user_data)
#define const
Definition: zconf.h:124
#define IMPLEMENT_COLLISION_TREE (   base_class,
  node 
)
Value:
public: \
/* Constructor / Destructor */ \
base_class(); \
virtual ~base_class(); \
/* Builds from a standard tree */ \
override(AABBOptimizedTree) bool Build(AABBTree* tree); \
/* Refits the tree */ \
override(AABBOptimizedTree) bool Refit(const MeshInterface* mesh_interface); \
/* Walks the tree */ \
override(AABBOptimizedTree) bool Walk(GenericWalkingCallback callback, void* user_data) const; \
/* Data access */ \
inline_ const node* GetNodes() const { return mNodes; } \
/* Stats */ \
override(AABBOptimizedTree) udword GetUsedBytes() const { return mNbNodes*sizeof(node); } \
private: \
node* mNodes;
#define inline_
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65
#define override(base_class)
bool(* GenericWalkingCallback)(const void *current, void *user_data)
#define const
Definition: zconf.h:124

Common interface for a collision tree.

Definition at line 128 of file Opcode.h.

#define IMPLEMENT_IMPLICIT_NODE (   base_class,
  volume 
)
Value:
public: \
/* Constructor / Destructor */ \
inline_ base_class() : mData(0) {} \
inline_ ~base_class() {} \
/* Leaf test */ \
inline_ BOOL IsLeaf() const { return mData&1; } \
/* Data access */ \
inline_ const base_class* GetPos() const { return (base_class*)mData; } \
inline_ const base_class* GetNeg() const { return ((base_class*)mData)+1; } \
/* Modified by S-cubed, Inc. */ \
inline_ const base_class* GetB() const { return mB; } \
inline_ udword GetPrimitive() const { return (mData>>1); } \
/* Stats */ \
inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \
\
volume mAABB; \
EXWORD mData; \
/* Modified by S-cubed, Inc. */ \
base_class* mB;
#define EXWORD
Definition: Opcode.h:27
#define inline_
#define SIZEOFOBJECT
Gives the size of current object. Avoid some mistakes (e.g. "sizeof(this)").
int BOOL
Another boolean type.
Definition: IceTypes.h:102
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65

Common interface for a node of an implicit tree.

Definition at line 31 of file Opcode.h.

#define IMPLEMENT_IMPLICIT_NODE (   base_class,
  volume 
)
Value:
public: \
/* Constructor / Destructor */ \
inline_ base_class() : mData(0) {} \
inline_ ~base_class() {} \
/* Leaf test */ \
inline_ BOOL IsLeaf() const { return mData&1; } \
/* Data access */ \
inline_ const base_class* GetPos() const { return (base_class*)mData; } \
inline_ const base_class* GetNeg() const { return ((base_class*)mData)+1; } \
/* Modified by S-cubed, Inc. */ \
inline_ const base_class* GetB() const { return mB; } \
inline_ udword GetPrimitive() const { return (mData>>1); } \
/* Stats */ \
inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \
\
volume mAABB; \
EXWORD mData; \
/* Modified by S-cubed, Inc. */ \
base_class* mB;
#define EXWORD
#define inline_
#define SIZEOFOBJECT
Gives the size of current object. Avoid some mistakes (e.g. "sizeof(this)").
int BOOL
Another boolean type.
Definition: IceTypes.h:102
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65
#define IMPLEMENT_NOLEAF_NODE (   base_class,
  volume 
)
Value:
public: \
/* Constructor / Destructor */ \
inline_ base_class() : mPosData(0), mNegData(0) {} \
inline_ ~base_class() {} \
/* Leaf tests */ \
inline_ BOOL HasPosLeaf() const { return mPosData&1; } \
inline_ BOOL HasNegLeaf() const { return mNegData&1; } \
/* Data access */ \
inline_ const base_class* GetPos() const { return (base_class*)mPosData; } \
inline_ const base_class* GetNeg() const { return (base_class*)mNegData; } \
/* Modified by S-cubed, Inc. */ \
inline_ const base_class* GetB() const { return mB; } \
inline_ udword GetPosPrimitive() const { return (mPosData>>1); } \
inline_ udword GetNegPrimitive() const { return (mNegData>>1); } \
/* Stats */ \
inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \
\
volume mAABB; \
EXWORD mPosData; \
EXWORD mNegData; \
/* Modified by S-cubed, Inc. */ \
base_class* mB;
#define EXWORD
Definition: Opcode.h:27
#define inline_
#define SIZEOFOBJECT
Gives the size of current object. Avoid some mistakes (e.g. "sizeof(this)").
int BOOL
Another boolean type.
Definition: IceTypes.h:102
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65

Common interface for a node of a no-leaf tree.

Definition at line 53 of file Opcode.h.

#define IMPLEMENT_NOLEAF_NODE (   base_class,
  volume 
)
Value:
public: \
/* Constructor / Destructor */ \
inline_ base_class() : mPosData(0), mNegData(0) {} \
inline_ ~base_class() {} \
/* Leaf tests */ \
inline_ BOOL HasPosLeaf() const { return mPosData&1; } \
inline_ BOOL HasNegLeaf() const { return mNegData&1; } \
/* Data access */ \
inline_ const base_class* GetPos() const { return (base_class*)mPosData; } \
inline_ const base_class* GetNeg() const { return (base_class*)mNegData; } \
/* Modified by S-cubed, Inc. */ \
inline_ const base_class* GetB() const { return mB; } \
inline_ udword GetPosPrimitive() const { return (mPosData>>1); } \
inline_ udword GetNegPrimitive() const { return (mNegData>>1); } \
/* Stats */ \
inline_ udword GetNodeSize() const { return SIZEOFOBJECT; } \
\
volume mAABB; \
EXWORD mPosData; \
EXWORD mNegData; \
/* Modified by S-cubed, Inc. */ \
base_class* mB;
#define EXWORD
#define inline_
#define SIZEOFOBJECT
Gives the size of current object. Avoid some mistakes (e.g. "sizeof(this)").
int BOOL
Another boolean type.
Definition: IceTypes.h:102
unsigned int udword
sizeof(udword) must be 4
Definition: IceTypes.h:65

Typedef Documentation

typedef bool(* GenericWalkingCallback) (const void *current, void *user_data)

Definition at line 145 of file OPC_OptimizedTree.h.



openhrp3
Author(s): AIST, General Robotix Inc., Nakamura Lab of Dept. of Mechano Informatics at University of Tokyo
autogenerated on Sat Apr 13 2019 02:14:27