moab
|
#include <EdgeSizeEvaluator.hpp>
Public Member Functions | |
EdgeSizeEvaluator () | |
Construct an evaluator. | |
virtual | ~EdgeSizeEvaluator () |
Destruction is virtual so subclasses may clean up after refinement. | |
virtual bool | evaluate_edge (const double *p0, const void *t0, double *p1, void *t1, const double *p2, const void *t2)=0 |
Returns true if the edge p0 - p2 should be subdivided, false otherwise. | |
void | set_tag_manager (RefinerTagManager *tmgr) |
RefinerTagManager * | get_tag_manager () |
Protected Attributes | |
RefinerTagManager * | tag_manager |
This is an abstract class that embodies the rule used during edge-based mesh refinement to decide whether an edge should be subdivided or not. Subclasses must implement the pure virtual evaluate_edge() function.
Definition at line 33 of file EdgeSizeEvaluator.hpp.
Construct an evaluator.
Definition at line 11 of file EdgeSizeEvaluator.cpp.
{ this->tag_manager = 0; }
moab::EdgeSizeEvaluator::~EdgeSizeEvaluator | ( | ) | [virtual] |
Destruction is virtual so subclasses may clean up after refinement.
Definition at line 17 of file EdgeSizeEvaluator.cpp.
{ }
bool moab::EdgeSizeEvaluator::evaluate_edge | ( | const double * | p0, |
const void * | t0, | ||
double * | p1, | ||
void * | t1, | ||
const double * | p2, | ||
const void * | t2 | ||
) | [pure virtual] |
Returns true if the edge p0 - p2 should be subdivided, false otherwise.
The arguments p0, p1, and p2 are all pointers to arrays of 6 doubles each while the arguments t0, t1, and t2 are all pointers to arrays of tag data defined at the corresponding point. While the endpoints p0 and p2 are immutable, the mid-edge point coordinates p1 and tag data t1 may be altered by evaluate_edge(). Altered values will be ignored if evaluate_edge() returns false. Be careful to ensure that all calls to evaluate_edge() perform identical modifications given identical input values!
A list of tags passed in t0, t1, and t2 is stored in the vertex_tags member. The vertex_size member stores the total length of data associated with each pointer (in bytes). Subclasses may access vertex_tags and vertexSize directly; the refiner uses public methods to populate vertex_tags before evaluate_edge() is called.
Implemented in moab::EdgeSizeSimpleImplicit.
RefinerTagManager* moab::EdgeSizeEvaluator::get_tag_manager | ( | ) | [inline] |
Definition at line 45 of file EdgeSizeEvaluator.hpp.
{ return this->tag_manager; }
void moab::EdgeSizeEvaluator::set_tag_manager | ( | RefinerTagManager * | tmgr | ) | [inline] |
Definition at line 44 of file EdgeSizeEvaluator.hpp.
{ this->tag_manager = tmgr; }
RefinerTagManager* moab::EdgeSizeEvaluator::tag_manager [protected] |
Definition at line 48 of file EdgeSizeEvaluator.hpp.