sofa::component::topology::Quad2TriangleTopologicalMapping Class Reference

This class, called Quad2TriangleTopologicalMapping, is a specific implementation of the interface TopologicalMapping where :. More...

#include <Quad2TriangleTopologicalMapping.h>

Inheritance diagram for sofa::component::topology::Quad2TriangleTopologicalMapping:

Inheritance graph
[legend]
Collaboration diagram for sofa::component::topology::Quad2TriangleTopologicalMapping:

Collaboration graph
[legend]

Public Member Functions

 Quad2TriangleTopologicalMapping (In *from=NULL, Out *to=NULL)
 Constructor.
virtual ~Quad2TriangleTopologicalMapping ()
 Destructor.
virtual void init ()
 Initializes the target BaseTopology from the source BaseTopology.
virtual void updateTopologicalMapping ()
 Translates the TopologyChange objects from the source to the target.
virtual unsigned int getFromIndex (unsigned int ind)

Static Public Member Functions

template<class T >
static bool canCreate (T *&obj, core::objectmodel::BaseContext *context, core::objectmodel::BaseObjectDescription *arg)
 Pre-construction check method called by ObjectFactory.
template<class T >
static void create (T *&obj, core::objectmodel::BaseContext *context, core::objectmodel::BaseObjectDescription *arg)
 Construction method called by ObjectFactory.

Protected Attributes

Data< std::string > object1
Data< std::string > object2

Detailed Description

This class, called Quad2TriangleTopologicalMapping, is a specific implementation of the interface TopologicalMapping where :.

INPUT TOPOLOGY = QuadSetTopology OUTPUT TOPOLOGY = TriangleSetTopology, as the constitutive elements of the INPUT TOPOLOGY

Quad2TriangleTopologicalMapping class is templated by the pair (INPUT TOPOLOGY, OUTPUT TOPOLOGY)

Definition at line 62 of file Quad2TriangleTopologicalMapping.h.


Constructor & Destructor Documentation

sofa::component::topology::Quad2TriangleTopologicalMapping::Quad2TriangleTopologicalMapping ( In *  from = NULL,
Out *  to = NULL 
)

Constructor.

Parameters:
from the topology issuing TopologyChange objects (the "source").
to the topology for which the TopologyChange objects must be translated (the "target").

Definition at line 73 of file Quad2TriangleTopologicalMapping.cpp.

sofa::component::topology::Quad2TriangleTopologicalMapping::~Quad2TriangleTopologicalMapping (  )  [virtual]

Destructor.

Does nothing.

Definition at line 81 of file Quad2TriangleTopologicalMapping.cpp.


Member Function Documentation

template<class T >
static bool sofa::component::topology::Quad2TriangleTopologicalMapping::canCreate ( T *&  obj,
core::objectmodel::BaseContext *  context,
core::objectmodel::BaseObjectDescription *  arg 
) [inline, static]

Pre-construction check method called by ObjectFactory.

This implementation read the object1 and object2 attributes and check if they are compatible with the input and output topology types of this mapping.

Reimplemented from sofa::core::objectmodel::BaseObject.

Definition at line 101 of file Quad2TriangleTopologicalMapping.h.

References sofa::core::objectmodel::Base::className(), sofa::core::objectmodel::BaseObjectDescription::findObject(), sofa::core::objectmodel::BaseContext::get(), sofa::core::objectmodel::BaseObjectDescription::getAttribute(), and sofa::core::objectmodel::BaseObject::getContext().

template<class T >
static void sofa::component::topology::Quad2TriangleTopologicalMapping::create ( T *&  obj,
core::objectmodel::BaseContext *  context,
core::objectmodel::BaseObjectDescription *  arg 
) [inline, static]

unsigned int sofa::component::topology::Quad2TriangleTopologicalMapping::getFromIndex ( unsigned int  ind  )  [virtual]

void sofa::component::topology::Quad2TriangleTopologicalMapping::init ( void   )  [virtual]

void sofa::component::topology::Quad2TriangleTopologicalMapping::updateTopologicalMapping (  )  [virtual]

Translates the TopologyChange objects from the source to the target.

Translates each of the TopologyChange objects waiting in the source list so that they have a meaning and reflect the effects of the first topology changes on the second topology.

Implements sofa::core::componentmodel::topology::TopologicalMapping.

Definition at line 144 of file Quad2TriangleTopologicalMapping.cpp.

References sofa::component::topology::TriangleSetTopologyModifier::addPointsProcess(), sofa::component::topology::PointSetTopologyModifier::addPointsWarning(), sofa::component::topology::TriangleSetTopologyModifier::addTrianglesProcess(), sofa::component::topology::TriangleSetTopologyModifier::addTrianglesWarning(), sofa::component::topology::PointsAdded::ancestorsList, sofa::component::topology::PointsAdded::coefs, sofa::core::componentmodel::topology::ENDING_EVENT, sofa::core::componentmodel::topology::BaseMeshTopology::firstChange(), sofa::core::componentmodel::topology::TopologicalMapping::fromModel, sofa::core::objectmodel::BaseContext::get(), sofa::core::objectmodel::BaseObject::getContext(), sofa::component::topology::PointsAdded::getNbAddedVertices(), sofa::core::componentmodel::topology::BaseMeshTopology::getNbQuads(), sofa::core::componentmodel::topology::BaseMeshTopology::getNbTriangles(), sofa::core::componentmodel::topology::BaseMeshTopology::getQuads(), sofa::core::componentmodel::topology::TopologicalMapping::In2OutMap, sofa::core::componentmodel::topology::BaseMeshTopology::lastChange(), sofa::core::componentmodel::topology::TopologicalMapping::Loc2GlobVec, sofa::component::topology::PointSetTopologyModifier::notifyEndingEvent(), sofa::core::componentmodel::topology::POINTSADDED, sofa::core::componentmodel::topology::POINTSREMOVED, sofa::core::componentmodel::topology::POINTSRENUMBERING, sofa::component::topology::PointSetTopologyModifier::propagateTopologicalChanges(), sofa::core::componentmodel::topology::QUADSADDED, sofa::core::componentmodel::topology::QUADSREMOVED, sofa::component::topology::TriangleSetTopologyModifier::removePointsProcess(), sofa::component::topology::PointSetTopologyModifier::removePointsWarning(), sofa::component::topology::TriangleSetTopologyModifier::removeTriangles(), sofa::component::topology::TriangleSetTopologyModifier::renumberPointsProcess(), sofa::component::topology::PointSetTopologyModifier::renumberPointsWarning(), and sofa::core::componentmodel::topology::TopologicalMapping::toModel.


Field Documentation

Definition at line 158 of file Quad2TriangleTopologicalMapping.h.

Definition at line 159 of file Quad2TriangleTopologicalMapping.h.


The documentation for this class was generated from the following files:

Generated on Sun Nov 23 04:21:33 2008 for Sofa by  doxygen 1.5.7.1