diff options
Diffstat (limited to 'source/blender/freestyle/intern/view_map/Silhouette.h')
-rw-r--r-- | source/blender/freestyle/intern/view_map/Silhouette.h | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/source/blender/freestyle/intern/view_map/Silhouette.h b/source/blender/freestyle/intern/view_map/Silhouette.h index d838b98c1a8..94b00157ccd 100644 --- a/source/blender/freestyle/intern/view_map/Silhouette.h +++ b/source/blender/freestyle/intern/view_map/Silhouette.h @@ -378,6 +378,17 @@ public: _FEdges.push_back(iFEdge); } + /*! Remove an FEdge from the list of edges emanating from this SVertex. */ + inline void RemoveFEdge(FEdge *iFEdge) + { + for (vector<FEdge *>::iterator fe = _FEdges.begin(), fend = _FEdges.end(); fe != fend; fe++) { + if (iFEdge == (*fe)) { + _FEdges.erase(fe); + break; + } + } + } + /* replaces edge 1 by edge 2 in the list of edges */ inline void Replace(FEdge *e1, FEdge *e2) { @@ -441,6 +452,10 @@ public: /*! angle in radians */ inline real curvature2d_as_angle() const; #endif + +#ifdef WITH_CXX_GUARDEDALLOC + MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SVertex") +#endif }; /**********************************/ @@ -518,6 +533,8 @@ protected: bool _isInImage; + bool _isTemporary; + public: /*! A field that can be used by the user to store any data. * This field must be reseted afterwards using ResetUserData(). @@ -538,6 +555,7 @@ public: _occludeeEmpty = true; _isSmooth = false; _isInImage = true; + _isTemporary = false; } /*! Builds an FEdge going from vA to vB. */ @@ -554,6 +572,7 @@ public: _occludeeEmpty = true; _isSmooth = false; _isInImage = true; + _isTemporary = false; } /*! Copy constructor */ @@ -573,6 +592,7 @@ public: _occludeeEmpty = iBrother._occludeeEmpty; _isSmooth = iBrother._isSmooth; _isInImage = iBrother._isInImage; + _isTemporary = iBrother._isTemporary; iBrother.userdata = this; userdata = 0; } @@ -708,6 +728,11 @@ public: return _isInImage; } + inline bool isTemporary() const + { + return _isTemporary; + } + /* modifiers */ /*! Sets the first SVertex. */ inline void setVertexA(SVertex *vA) @@ -803,6 +828,11 @@ public: _isInImage = iFlag; } + inline void setTemporary(bool iFlag) + { + _isTemporary = iFlag; + } + /* checks whether two FEdge have a common vertex. * Returns a pointer on the common vertex if it exists, NULL otherwise. */ @@ -931,6 +961,10 @@ public: * The sampling with which we want to iterate over points of this FEdge. */ virtual inline Interface0DIterator pointsEnd(float t = 0.0f); + +#ifdef WITH_CXX_GUARDEDALLOC + MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdge") +#endif }; // @@ -1241,6 +1275,10 @@ public: { _bFaceMark = iFaceMark; } + +#ifdef WITH_CXX_GUARDEDALLOC + MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdgeSharp") +#endif }; /*! Class defining a smooth edge. This kind of edge typically runs across a face of the input mesh. It can be @@ -1353,6 +1391,10 @@ public: { _FrsMaterialIndex = i; } + +#ifdef WITH_CXX_GUARDEDALLOC + MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdgeSmooth") +#endif }; |