Documentation


animal::octree::Octree Class Reference

#include <Octree.h>

Inheritance diagram for animal::octree::Octree:

animal::octree::FastOctree< T, S, U > animal::octree::OctreeEngine animal::octree::OctreeParticleSystemEngine< t_Vector, t_Real, t_Masses > animal::octree::OctreeODEEngine animal::octree::OctreeSpringEngine List of all members.

Public Member Functions

 Octree (Vec3d bboxMin, Vec3d bboxMax, MFVec3f *points, MFVec3f normals, unsigned int nMaxPointsPerCell=1)
 ~Octree ()
unsigned int getNMaxPointsPerCell ()
void setNMaxPointsPerCell (unsigned int n)
 Set the maximum number of points per cell and update the octree by subdividing/simplifying cells if needed Require : n!=0.

void setPositionMethod (int m)
int getPositionMethod () const
void subdivideDeformed (Cell *cell)
void subdivideRecDeformed (Cell *cell)
void simplify (Cell *cell)
void updateFrames (ConstrainedVertex *vertex, Cell *cell, unsigned int vPos)
void updateCellFrames (Cell *cell)
void movedRecLeaves (Cell *cell)
void structureChangedRecLeaves (Cell *cell)
void updateCellsData (Cell *cell)
void directManipulation (SFVec3fCellConstrained *vertex, Vec3d newPosition)
std::vector< Vec3dgetNormals () const
OctreeDataPointsgetMeshVertices ()
void setFreeFrames (bool)
bool haveFreeFrames () const
void setDMMethod (int method)

Static Public Member Functions

void updateFrame (Cell *cell)
void updateFrames (Cell *cell)
void moved (Cell *cell)
void structureChanged (Cell *cell)
void updateVertexInformationsRec (Cell *cell)
 Update the relativePosition data in the OctreeDataPoints.

void updateVertexInformationsRecLeaves (Cell *cell)
void updateVertexInformations (Cell *cell)
void updateInfluenceMapsRecLeaves (Cell *cell)
void updateInfluenceMaps (Cell *cell)

Private Member Functions

int createOctree (Cell *cell, std::deque< SFVec3f * > pointsIn)
int createOctree (Cell *cell)
void updateHierarchy (Cell *cell)
bool isLeaf (Cell *cell)

Private Attributes

unsigned int _nMaxPointsPerCell
int _optionPositionMethod
bool _freeFrames
int _DMMethod

Constructor & Destructor Documentation

animal::octree::Octree::Octree Vec3d  bboxMin,
Vec3d  bboxMax,
MFVec3f points,
MFVec3f  normals,
unsigned int  nMaxPointsPerCell = 1
 

Definition at line 532 of file Octree.cpp.

References createOctree(), getNMaxPointsPerCell(), animal::octree::LINEAR, animal::octree::LOCAL_SKINNING, animal::octree::OCTREE_DM_NOTHING, Require, animal::octree::FastOctree< T, S, U >::root(), structureChangedRecLeaves(), animal::octree::TempOctree, updateVertexInformations(), and animal::octree::Vec3d.

animal::octree::Octree::~Octree  ) 
 

Definition at line 594 of file Octree.cpp.


Member Function Documentation

int animal::octree::Octree::createOctree Cell cell  )  [private]
 

Definition at line 621 of file Octree.cpp.

References animal::octree::Cell, createOctree(), getNMaxPointsPerCell(), and subdivideDeformed().

int animal::octree::Octree::createOctree Cell cell,
std::deque< SFVec3f * >  pointsIn
[private]
 

Referenced by createOctree(), and Octree().

void animal::octree::Octree::directManipulation SFVec3fCellConstrained vertex,
Vec3d  newPosition
 

Definition at line 1186 of file Octree.cpp.

References _DMMethod, animal::octree::Cell, animal::octree::computeDirectManipulationResultPseudoInverse(), animal::octree::computeDirectManipulationSkinning(), animal::octree::computeDirectManipulationSkinningFrames(), animal::octree::computeDirectManipulationSkinningVertices(), animal::octree::computeDirectManipulationSkinningVerticesAndFrames(), animal::octree::SFVec3fCellConstrained::computeWeight(), animal::octree::SFVec3fCellConstrained::getCell(), animal::octree::SFVec3fCellConstrained::getLocalParams(), animal::octree::Frame::getOrigin(), animal::octree::SFVec3fCellConstrained::getParameters(), getPositionMethod(), animal::octree::SFVec3fCellConstrained::getRelativePosition(), animal::octree::SFVec3fCellConstrained::getRelativeWeight(), animal::octree::SFVec3fCellConstrained::getSFVec3f(), animal::octree::Frame::getVector(), haveFreeFrames(), animal::octree::LINEAR, animal::octree::LOCAL_SKINNING, movedRecLeaves(), animal::octree::OCTREE_DM_FRAMES, animal::octree::OCTREE_DM_VERTICES, Require, animal::octree::FastOctree< T, S, U >::root(), animal::octree::Frame::setOrigin(), animal::octree::Frame::setVector(), animal::octree::Vec3d, and animal::octree::CellInfluenceData::vertices.

Referenced by animal::octree::ManipulatedMeshVertexAnimated< t_Vector, t_Real, t_VecReal >::moveTo(), animal::octree::ManipulatedMeshVertex::moveTo(), and X3DTK::X3D::DeformableOctreeNode::slotButtonDirectManipulation().

OctreeDataPoints & animal::octree::Octree::getMeshVertices  ) 
 

Definition at line 1425 of file Octree.cpp.

References animal::octree::OctreeDataPoints, and animal::octree::FastOctree< T, S, U >::root().

unsigned int animal::octree::Octree::getNMaxPointsPerCell  ) 
 

Definition at line 645 of file Octree.cpp.

References _nMaxPointsPerCell.

Referenced by createOctree(), X3DTK::X3D::DeformableOctreeNode::getOptionNMaxPointsPerCell(), Octree(), and updateHierarchy().

std::vector< Vec3d > animal::octree::Octree::getNormals  )  const
 

Definition at line 1409 of file Octree.cpp.

References animal::octree::Cell, and animal::octree::FastOctree< T, S, U >::root().

int animal::octree::Octree::getPositionMethod  )  const
 

Definition at line 702 of file Octree.cpp.

References _optionPositionMethod.

Referenced by directManipulation(), and movedRecLeaves().

bool animal::octree::Octree::haveFreeFrames  )  const [inline]
 

Definition at line 115 of file Octree.h.

References _freeFrames.

Referenced by directManipulation(), movedRecLeaves(), structureChangedRecLeaves(), and subdivideDeformed().

bool animal::octree::Octree::isLeaf Cell cell  )  [inline, private]
 

Definition at line 133 of file Octree.h.

References animal::octree::Cell.

void animal::octree::Octree::moved Cell cell  )  [static]
 

Definition at line 890 of file Octree.cpp.

References animal::octree::_globalPositionMethod, animal::octree::Cell, and animal::octree::OctreeDataPoints.

Referenced by movedRecLeaves().

void animal::octree::Octree::movedRecLeaves Cell cell  ) 
 

Definition at line 873 of file Octree.cpp.

References animal::octree::_globalPositionMethod, animal::octree::Cell, getPositionMethod(), animal::octree::GLOBAL_LINEAR, haveFreeFrames(), moved(), and updateFrames().

Referenced by directManipulation(), animal::octree::OctreeParticleSystemEngine< t_Vector, t_Real, t_Masses >::move(), animal::octree::OctreeEngine::move(), animal::octree::ManipulatedMeshVertexAnimated< t_Vector, t_Real, t_VecReal >::moveTo(), animal::octree::ManipulatedMeshVertex::moveTo(), simplify(), X3DTK::X3D::DeformableOctreeNode::slotButtonDirectManipulation(), X3DTK::X3D::DeformableOctreeNode::slotMoveXMinus(), X3DTK::X3D::DeformableOctreeNode::slotMoveXPlus(), X3DTK::X3D::DeformableOctreeNode::slotMoveYMinus(), X3DTK::X3D::DeformableOctreeNode::slotMoveYPlus(), X3DTK::X3D::DeformableOctreeNode::slotMoveZMinus(), X3DTK::X3D::DeformableOctreeNode::slotMoveZPlus(), X3DTK::X3D::DeformableOctreeNode::slotSetInterpolationMethod(), and subdivideRecDeformed().

void animal::octree::Octree::setDMMethod int  method  ) 
 

Definition at line 601 of file Octree.cpp.

References _DMMethod, animal::octree::OCTREE_DM_FRAMES, animal::octree::OCTREE_DM_NOTHING, animal::octree::OCTREE_DM_VERTICES, and Require.

void animal::octree::Octree::setFreeFrames bool   ) 
 

Definition at line 608 of file Octree.cpp.

References _freeFrames.

void animal::octree::Octree::setNMaxPointsPerCell unsigned int  n  ) 
 

Set the maximum number of points per cell and update the octree by subdividing/simplifying cells if needed Require : n!=0.

Definition at line 650 of file Octree.cpp.

References _nMaxPointsPerCell, Require, animal::octree::FastOctree< T, S, U >::root(), and updateHierarchy().

Referenced by X3DTK::X3D::DeformableOctreeNode::slotSetNMaxPointsPerCell().

void animal::octree::Octree::setPositionMethod int  m  ) 
 

Set the interpolation method for calcing mesh' vertices position

Definition at line 691 of file Octree.cpp.

References _optionPositionMethod, animal::octree::FastOctree< T, S, U >::root(), animal::octree::ConstrainedVertex::setDelta(), and animal::octree::Vec3d.

Referenced by X3DTK::X3D::DeformableOctreeNode::slotSetInterpolationMethod().

void animal::octree::Octree::simplify Cell cell  ) 
 

Simplify a cell

Definition at line 1000 of file Octree.cpp.

References animal::octree::Cell, movedRecLeaves(), animal::octree::FastOctree< T, S, U >::root(), structureChangedRecLeaves(), updateInfluenceMapsRecLeaves(), and updateVertexInformationsRecLeaves().

Referenced by X3DTK::X3D::DeformableOctreeNode::slotSimplify().

void animal::octree::Octree::structureChanged Cell cell  )  [static]
 

Definition at line 959 of file Octree.cpp.

References animal::octree::Cell, updateInfluenceMaps(), and updateVertexInformations().

Referenced by structureChangedRecLeaves().

void animal::octree::Octree::structureChangedRecLeaves Cell cell  ) 
 

Definition at line 903 of file Octree.cpp.

References animal::octree::Cell, animal::octree::Frame::getVector(), haveFreeFrames(), animal::octree::Frame::setOrigin(), animal::octree::Frame::setVector(), structureChanged(), and updateFrames().

Referenced by Octree(), simplify(), and subdivideRecDeformed().

void animal::octree::Octree::subdivideDeformed Cell cell  ) 
 

Subdivide a cell of any type

Definition at line 716 of file Octree.cpp.

References animal::octree::Cell, animal::octree::SFVec3fCellConstrained::computeDerivative(), animal::octree::SFVec3fCellConstrained::computePosition(), Ensure, haveFreeFrames(), animal::octree::LOCAL_SKINNING, Require, animal::octree::SFVec3fCellConstrained::setParams(), animal::octree::SFVec3fCellConstrained::updateSkinningInformations(), and animal::octree::Vec3d.

Referenced by createOctree(), subdivideRecDeformed(), and updateHierarchy().

void animal::octree::Octree::subdivideRecDeformed Cell cell  ) 
 

Subdivide recursively this cell meaning that we subdivide every leaf cell

Definition at line 849 of file Octree.cpp.

References animal::octree::Cell, movedRecLeaves(), animal::octree::FastOctree< T, S, U >::root(), structureChangedRecLeaves(), and subdivideDeformed().

Referenced by X3DTK::X3D::DeformableOctreeNode::slotSubdivide().

void animal::octree::Octree::updateCellFrames Cell cell  ) 
 

void animal::octree::Octree::updateCellsData Cell cell  ) 
 

Definition at line 1086 of file Octree.cpp.

References animal::octree::Cell, and animal::octree::OctreeDataPoints.

void animal::octree::Octree::updateFrame Cell cell  )  [static]
 

Update the frames depending on the cell

Definition at line 1026 of file Octree.cpp.

References animal::octree::Cell.

void animal::octree::Octree::updateFrames ConstrainedVertex vertex,
Cell cell,
unsigned int  vPos
 

Definition at line 1054 of file Octree.cpp.

References animal::octree::Cell.

void animal::octree::Octree::updateFrames Cell cell  )  [static]
 

Definition at line 1036 of file Octree.cpp.

References animal::octree::Cell.

Referenced by movedRecLeaves(), and structureChangedRecLeaves().

void animal::octree::Octree::updateHierarchy Cell cell  )  [private]
 

Definition at line 660 of file Octree.cpp.

References animal::octree::Cell, getNMaxPointsPerCell(), and subdivideDeformed().

Referenced by setNMaxPointsPerCell().

void animal::octree::Octree::updateInfluenceMaps Cell cell  )  [static]
 

Definition at line 1128 of file Octree.cpp.

References animal::octree::Cell, animal::octree::CellInfluenceData::firstCellVertexParameters, animal::octree::getFirstVertexParametersInCell(), animal::octree::getVertexFreeCell(), animal::octree::getVertexPositionInCell(), animal::octree::getWeightsHash(), animal::octree::CellInfluenceData::influenceMaps, animal::octree::CellInfluenceData::parents, animal::octree::CellInfluenceData::vertices, and animal::octree::CellInfluenceData::verticesId.

Referenced by structureChanged(), and updateInfluenceMapsRecLeaves().

void animal::octree::Octree::updateInfluenceMapsRecLeaves Cell cell  )  [static]
 

Definition at line 1120 of file Octree.cpp.

References animal::octree::Cell, and updateInfluenceMaps().

Referenced by simplify().

void animal::octree::Octree::updateVertexInformations Cell cell  )  [static]
 

Definition at line 988 of file Octree.cpp.

References animal::octree::Cell.

Referenced by Octree(), structureChanged(), updateVertexInformationsRec(), and updateVertexInformationsRecLeaves().

void animal::octree::Octree::updateVertexInformationsRec Cell cell  )  [static]
 

Update the relativePosition data in the OctreeDataPoints.

Definition at line 975 of file Octree.cpp.

References animal::octree::Cell, and updateVertexInformations().

void animal::octree::Octree::updateVertexInformationsRecLeaves Cell cell  )  [static]
 

Definition at line 981 of file Octree.cpp.

References animal::octree::Cell, and updateVertexInformations().

Referenced by simplify().


Member Data Documentation

int animal::octree::Octree::_DMMethod [private]
 

Definition at line 139 of file Octree.h.

Referenced by directManipulation(), and setDMMethod().

bool animal::octree::Octree::_freeFrames [private]
 

Definition at line 137 of file Octree.h.

Referenced by haveFreeFrames(), and setFreeFrames().

unsigned int animal::octree::Octree::_nMaxPointsPerCell [private]
 

Definition at line 127 of file Octree.h.

Referenced by getNMaxPointsPerCell(), and setNMaxPointsPerCell().

int animal::octree::Octree::_optionPositionMethod [private]
 

Definition at line 131 of file Octree.h.

Referenced by getPositionMethod(), and setPositionMethod().


The documentation for this class was generated from the following files:
Generated on Thu Dec 23 13:52:33 2004 by doxygen 1.3.6