#include <InterpKernelGeo2DEdge.hxx>

Public Member Functions | |
| Edge (Node *start, Node *end, bool direction=true) | |
| Edge (double sX, double sY, double eX, double eY) | |
| TypeOfEdgeLocInPolygon | getLoc () const |
| void | incrRef () const |
| bool | decrRef () |
| void | initLocs () const |
| void | declareOn () const |
| void | declareIn () const |
| void | declareOut () const |
| const Bounds & | getBounds () const |
| void | fillXfigStreamForLoc (std::ostream &stream) const |
| Node * | getNode (TypeOfLocInEdge where) const |
| Node * | getStartNode () const |
| Node * | getEndNode () const |
| void | setEndNodeWithoutChange (Node *newEnd) |
| void | setStartNodeWithoutChange (Node *newStart) |
| bool | changeStartNodeWith (Node *otherStartNode) const |
| bool | changeStartNodeWithAndKeepTrack (Node *otherStartNode, std::vector< Node * > &track) const |
| bool | changeEndNodeWith (Node *otherEndNode) const |
| bool | changeEndNodeWithAndKeepTrack (Node *otherEndNode, std::vector< Node * > &track) const |
| void | addSubEdgeInVector (Node *start, Node *end, ComposedEdge &vec) const |
| void | getNormalVector (double *vectOutput) const |
| virtual void | update (Node *m)=0 |
| virtual double | getAreaOfZone () const =0 |
| returns area between this and axe Ox delimited along Ox by _start and _end. | |
| virtual void | applySimilarity (double xBary, double yBary, double dimChar) |
| apply a similiraty transformation on 'this' | |
| virtual double | getCurveLength () const =0 |
| return the length of arc. Value is always > 0. ! | |
| virtual void | getBarycenter (double *bary) const =0 |
| virtual void | getBarycenterOfZone (double *bary) const =0 |
| virtual Node * | buildRepresentantOfMySelf () const =0 |
| Retrieves a point that is owning to this, well placed for IN/OUT detection of this. Typically midlle of this is returned. | |
| virtual bool | isIn (double characterVal) const =0 |
| Given a magnitude specified by sub-type returns if in or not. See getCharactValue method. | |
| virtual bool | isLower (double val1, double val2) const =0 |
| With the same magnitude as defined in 'isIn' method perform a compararison. Precondition : val1 and val2 are different and exactly INSIDE this. | |
| virtual double | getCharactValue (const Node &node) const =0 |
| node is expected to lay on 'this'. It returns a characteristic magnitude usable by isIn method. | |
| virtual double | getDistanceToPoint (const double *pt) const =0 |
| retrieves the distance to this : The min distance from pt and any point of this. | |
| virtual bool | isNodeLyingOn (const double *coordOfNode) const =0 |
| return if node with coords 'coordOfNode' is on this (with precision). | |
| virtual TypeOfFunction | getTypeOfFunc () const =0 |
| virtual void | dynCastFunction (const EdgeLin *&seg, const EdgeArcCircle *&arcSeg) const =0 |
| bool | intersectWith (const Edge *other, MergePoints &commonNode, ComposedEdge &outVal1, ComposedEdge &outVal2) const |
| virtual void | dumpInXfigFile (std::ostream &stream, bool direction, int resolution, const Bounds &box) const =0 |
Static Public Member Functions | |
| static EdgeIntersector * | buildIntersectorWith (const Edge *e1, const Edge *e2) |
| static Edge * | buildFromXfigLine (std::istream &str) |
| static Edge * | buildEdgeFrom (Node *start, Node *end) |
| template<TypeOfMod4QuadEdge type> | |
| static Edge * | buildEdgeFrom (Node *start, Node *middle, Node *end) |
| static bool | intersectOverlapped (const Edge *f1, const Edge *f2, EdgeIntersector *intersector, MergePoints &commonNode, ComposedEdge &outValForF1, ComposedEdge &outValForF2) |
| static void | interpolate1DLin (const std::vector< double > &distrib1, const std::vector< double > &distrib2, std::map< int, std::map< int, double > > &result) |
Protected Member Functions | |
| Edge () | |
| virtual | ~Edge () |
| virtual Edge * | buildEdgeLyingOnMe (Node *start, Node *end, bool direction=true) const =0 |
Static Protected Member Functions | |
| static int | combineCodes (TypeOfLocInEdge code1, TypeOfLocInEdge code2) |
| static bool | intersect (const Edge *f1, const Edge *f2, EdgeIntersector *intersector, const Bounds *whereToFind, MergePoints &commonNode, ComposedEdge &outValForF1, ComposedEdge &outValForF2) |
| static bool | splitOverlappedEdges (const Edge *e1, const Edge *e2, Node *nS, Node *nE, bool direction, int code, ComposedEdge &outVal1, ComposedEdge &outVal2) |
| The code 'code' is built by method combineCodes. | |
Protected Attributes | |
| unsigned char | _cnt |
| TypeOfEdgeLocInPolygon | _loc |
| Bounds | _bounds |
| Node * | _start |
| Node * | _end |
Static Protected Attributes | |
| static const int | OFFSET_FOR_TYPEOFLOCINEDGE = 8 |
Deal with an oriented edge of a polygon. An Edge is definied with a start node a end node and an equation of 1D curve. All other attributes are mutable because they don't impact these 3 invariant attributes. To be exact start and end node can change (adress) but their location remain the same (at precision).
References med_test1.end, and INTERP_KERNEL.Node.incrRef().
| INTERP_KERNEL.Edge.Edge | ( | ) | [protected] |
| Edge::~Edge | ( | ) | [protected, virtual] |
References INTERP_KERNEL.Edge._end, INTERP_KERNEL.Edge._start, and INTERP_KERNEL.Node.decrRef().
| TypeOfEdgeLocInPolygon INTERP_KERNEL.Edge.getLoc | ( | ) | const |
| void INTERP_KERNEL.Edge.incrRef | ( | ) | const |
| bool Edge::decrRef | ( | ) |
References INTERP_KERNEL.Edge._cnt, and testMEDMEM.ret.
| void INTERP_KERNEL.Edge.initLocs | ( | ) | const |
References INTERP_KERNEL.FULL_UNKNOWN.
| void Edge::declareOn | ( | ) | const |
| void Edge::declareIn | ( | ) | const |
| void Edge::declareOut | ( | ) | const |
| const Bounds& INTERP_KERNEL.Edge.getBounds | ( | ) | const |
| void Edge::fillXfigStreamForLoc | ( | std::ostream & | stream | ) | const |
| Node* INTERP_KERNEL.Edge.getNode | ( | TypeOfLocInEdge | where | ) | const |
References INTERP_KERNEL.END, and INTERP_KERNEL.START.
| Node* INTERP_KERNEL.Edge.getStartNode | ( | ) | const |
| Node* INTERP_KERNEL.Edge.getEndNode | ( | ) | const |
| void INTERP_KERNEL.Edge.setEndNodeWithoutChange | ( | Node * | newEnd | ) |
| void INTERP_KERNEL.Edge.setStartNodeWithoutChange | ( | Node * | newStart | ) |
| bool Edge::changeStartNodeWith | ( | Node * | otherStartNode | ) | const |
| bool Edge::changeEndNodeWith | ( | Node * | otherEndNode | ) | const |
| void Edge::addSubEdgeInVector | ( | Node * | start, |
| Node * | end, | ||
| ComposedEdge & | vec | ||
| ) | const |
Precondition : 'start' and 'end' are lying on the same curve than 'this'. Add in vec the sub edge lying on this. If 'start' is equal (by pointer) to '_end' and 'end' is equal to '_end' too nothing is added. If 'start' is equal (by pointer) to '_start' and 'end' is equal to '_start' too nothing is added. If 'start' is equal (by pointer) to '_start' and 'end' is equal to '_end' this is added in vec.
References INTERP_KERNEL.Edge._end, INTERP_KERNEL.Edge._start, INTERP_KERNEL.Edge.buildEdgeLyingOnMe(), INTERP_KERNEL.Edge.incrRef(), and INTERP_KERNEL.ComposedEdge.pushBack().
| void Edge::getNormalVector | ( | double * | vectOutput | ) | const |
Retrieves a vector 'vectOutput' that is normal to 'this'. 'vectOutput' is normalized.
References INTERP_KERNEL.Edge._end, INTERP_KERNEL.Edge._start, and INTERP_KERNEL.norm().
| EdgeIntersector * Edge::buildIntersectorWith | ( | const Edge * | e1, |
| const Edge * | e2 | ||
| ) | [static] |
| Edge * Edge::buildFromXfigLine | ( | std::istream & | str | ) | [static] |
References medClient_test.type.
| static Edge* INTERP_KERNEL.Edge.buildEdgeFrom | ( | Node * | start, |
| Node * | middle, | ||
| Node * | end | ||
| ) | [static] |
| virtual void INTERP_KERNEL.Edge.update | ( | Node * | m | ) | [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual double INTERP_KERNEL.Edge.getAreaOfZone | ( | ) | const [pure virtual] |
returns area between this and axe Ox delimited along Ox by _start and _end.
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
apply a similiraty transformation on 'this'
See Node.applySimilarity to see signification of params.
Reimplemented in INTERP_KERNEL.EdgeArcCircle.
References INTERP_KERNEL.Edge._bounds, and INTERP_KERNEL.Bounds.applySimilarity().
| virtual double INTERP_KERNEL.Edge.getCurveLength | ( | ) | const [pure virtual] |
return the length of arc. Value is always > 0. !
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual void INTERP_KERNEL.Edge.getBarycenter | ( | double * | bary | ) | const [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual void INTERP_KERNEL.Edge.getBarycenterOfZone | ( | double * | bary | ) | const [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual Node* INTERP_KERNEL.Edge.buildRepresentantOfMySelf | ( | ) | const [pure virtual] |
Retrieves a point that is owning to this, well placed for IN/OUT detection of this. Typically midlle of this is returned.
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual bool INTERP_KERNEL.Edge.isIn | ( | double | characterVal | ) | const [pure virtual] |
Given a magnitude specified by sub-type returns if in or not. See getCharactValue method.
Implemented in INTERP_KERNEL.EdgeArcCircle, INTERP_KERNEL.EdgeInfLin, and INTERP_KERNEL.EdgeLin.
With the same magnitude as defined in 'isIn' method perform a compararison. Precondition : val1 and val2 are different and exactly INSIDE this.
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
node is expected to lay on 'this'. It returns a characteristic magnitude usable by isIn method.
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
retrieves the distance to this : The min distance from pt and any point of this.
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual bool INTERP_KERNEL.Edge.isNodeLyingOn | ( | const double * | coordOfNode | ) | const [pure virtual] |
return if node with coords 'coordOfNode' is on this (with precision).
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual TypeOfFunction INTERP_KERNEL.Edge.getTypeOfFunc | ( | ) | const [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| virtual void INTERP_KERNEL.Edge.dynCastFunction | ( | const EdgeLin *& | seg, |
| const EdgeArcCircle *& | arcSeg | ||
| ) | const [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, INTERP_KERNEL.EdgeInfLin, and INTERP_KERNEL.EdgeLin.
| bool Edge::intersectWith | ( | const Edge * | other, |
| MergePoints & | commonNode, | ||
| ComposedEdge & | outVal1, | ||
| ComposedEdge & | outVal2 | ||
| ) | const |
| other | The Edge with which we are going to intersect. |
| commonNode | Output. The common nodes found during operation of intersecting. |
| outVal1 | Output filled in case true is returned. It specifies the new or not new edges by which 'this' is replaced after intersecting op. |
| outVal2 | Output filled in case true is returned. It specifies the new or not new edges by which 'other' is replaced after intersecting op. return true if the intersection between this. |
References INTERP_KERNEL.Edge._bounds, INTERP_KERNEL.Edge.buildIntersectorWith(), INTERP_KERNEL.Edge.getBounds(), INTERP_KERNEL.Edge.intersect(), INTERP_KERNEL.Bounds.nearlyAmIIntersectingWith(), and testMEDMEM.ret.
| bool Edge::intersectOverlapped | ( | const Edge * | f1, |
| const Edge * | f2, | ||
| EdgeIntersector * | intersector, | ||
| MergePoints & | commonNode, | ||
| ComposedEdge & | outValForF1, | ||
| ComposedEdge & | outValForF2 | ||
| ) | [static] |
| void Edge::interpolate1DLin | ( | const std::vector< double > & | distrib1, |
| const std::vector< double > & | distrib2, | ||
| std::map< int, std::map< int, double > > & | result | ||
| ) | [static] |
Perform 1D linear interpolation. Warning distrib1 and distrib2 are expected to be in ascending mode.
References INTERP_KERNEL.SegSegIntersector.areOverlappedOrOnlyColinears(), INTERP_KERNEL.Node.decrRef(), INTERP_KERNEL.Edge.decrRef(), INTERP_KERNEL.ComposedEdge.Delete(), TestMedCorba4.e1, TestMedCorba4.e2, testDriverAscii.f1, INTERP_KERNEL.ComposedEdge.getCommonLengthWith(), INTERP_KERNEL.EdgeLin.getCurveLength(), INTERP_KERNEL.Edge.intersectOverlapped(), TestMedCorba4.n1, TestMedCorba4.n2, med_test_grid.n3, med_test_grid.n4, and INTERP_KERNEL.Node.setNewCoords().
| virtual void INTERP_KERNEL.Edge.dumpInXfigFile | ( | std::ostream & | stream, |
| bool | direction, | ||
| int | resolution, | ||
| const Bounds & | box | ||
| ) | const [pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
| int Edge::combineCodes | ( | TypeOfLocInEdge | code1, |
| TypeOfLocInEdge | code2 | ||
| ) | [static, protected] |
References INTERP_KERNEL.Edge.OFFSET_FOR_TYPEOFLOCINEDGE, and testMEDMEM.ret.
| bool Edge::intersect | ( | const Edge * | f1, |
| const Edge * | f2, | ||
| EdgeIntersector * | intersector, | ||
| const Bounds * | whereToFind, | ||
| MergePoints & | commonNode, | ||
| ComposedEdge & | outValForF1, | ||
| ComposedEdge & | outValForF2 | ||
| ) | [static, protected] |
| bool Edge::splitOverlappedEdges | ( | const Edge * | e1, |
| const Edge * | e2, | ||
| Node * | nS, | ||
| Node * | nE, | ||
| bool | direction, | ||
| int | code, | ||
| ComposedEdge & | outVal1, | ||
| ComposedEdge & | outVal2 | ||
| ) | [static, protected] |
The code 'code' is built by method combineCodes.
This method splits e1 and e2 into pieces as much sharable as possible. The precondition to the call of this method is that e1 and e2 have been declared as overlapped by corresponding intersector built from e1 and e2 type.
| nS | start node of e2 with the SAME DIRECTION as e1. The pointer nS should be equal to start node of e2 or to its end node. |
| nE | end node of e2 with the SAME DIRECTION as e1. The pointer nE should be equal to start node of e2 or to its end node. |
| direction | is param that specifies if e2 and e1 have same directions (true) or opposed (false). |
| code | is the code returned by method Edge.combineCodes. |
References INTERP_KERNEL.Edge.buildEdgeLyingOnMe(), INTERP_KERNEL.Edge.declareOn(), INTERP_KERNEL.END, INTERP_KERNEL.Edge.getCharactValue(), INTERP_KERNEL.Edge.getEndNode(), INTERP_KERNEL.Edge.getStartNode(), INTERP_KERNEL.Edge.incrRef(), INTERP_KERNEL.INSIDE, INTERP_KERNEL.Edge.isIn(), INTERP_KERNEL.Edge.OFFSET_FOR_TYPEOFLOCINEDGE, INTERP_KERNEL.OUT_AFTER, INTERP_KERNEL.OUT_BEFORE, INTERP_KERNEL.ComposedEdge.pushBack(), INTERP_KERNEL.ComposedEdge.resize(), INTERP_KERNEL.ComposedEdge.setValueAt(), and INTERP_KERNEL.START.
| virtual Edge* INTERP_KERNEL.Edge.buildEdgeLyingOnMe | ( | Node * | start, |
| Node * | end, | ||
| bool | direction = true |
||
| ) | const [protected, pure virtual] |
Implemented in INTERP_KERNEL.EdgeArcCircle, and INTERP_KERNEL.EdgeLin.
unsigned char INTERP_KERNEL.Edge._cnt [mutable, protected] |
TypeOfEdgeLocInPolygon INTERP_KERNEL.Edge._loc [mutable, protected] |
Bounds INTERP_KERNEL.Edge._bounds [protected] |
Node* INTERP_KERNEL.Edge._start [protected] |
Node* INTERP_KERNEL.Edge._end [protected] |
const int INTERP_KERNEL.Edge.OFFSET_FOR_TYPEOFLOCINEDGE = 8 [static, protected] |