Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/freestyle/intern/stroke/Chain.cpp')
-rw-r--r--source/blender/freestyle/intern/stroke/Chain.cpp27
1 files changed, 18 insertions, 9 deletions
diff --git a/source/blender/freestyle/intern/stroke/Chain.cpp b/source/blender/freestyle/intern/stroke/Chain.cpp
index d4cc4fd68c3..79d174d8117 100644
--- a/source/blender/freestyle/intern/stroke/Chain.cpp
+++ b/source/blender/freestyle/intern/stroke/Chain.cpp
@@ -45,10 +45,12 @@ void Chain::push_viewedge_back(ViewEdge *iViewEdge, bool orientation)
if (!_Vertices.empty()) {
previous = _Vertices.back()->point2d();
- if (orientation)
+ if (orientation) {
++v;
- else
+ }
+ else {
--v;
+ }
// Ensure the continuity of underlying FEdges
CurvePoint *cp =
_Vertices.back(); // assumed to be instantiated as new CurvePoint(iSVertex, 0, 0.f);
@@ -69,10 +71,12 @@ void Chain::push_viewedge_back(ViewEdge *iViewEdge, bool orientation)
Curve::push_vertex_back(*v);
//_Length += (current - previous).norm();
previous = current;
- if (orientation)
+ if (orientation) {
++v;
- else
+ }
+ else {
--v;
+ }
} while ((v != vend) && (v != vfirst));
if (v == vfirst) {
@@ -105,10 +109,12 @@ void Chain::push_viewedge_front(ViewEdge *iViewEdge, bool orientation)
if (!_Vertices.empty()) {
previous = _Vertices.front()->point2d();
- if (orientation)
+ if (orientation) {
++v;
- else
+ }
+ else {
--v;
+ }
// Ensure the continuity of underlying FEdges
CurvePoint *cp =
_Vertices.front(); // assumed to be instantiated as new CurvePoint(iSVertex, 0, 0.f);
@@ -131,10 +137,12 @@ void Chain::push_viewedge_front(ViewEdge *iViewEdge, bool orientation)
Curve::push_vertex_front((*v));
//_Length += (current - previous).norm();
previous = current;
- if (orientation)
+ if (orientation) {
++v;
- else
+ }
+ else {
--v;
+ }
} while ((v != vend) && (v != vfirst));
if (v == vfirst) {
@@ -144,8 +152,9 @@ void Chain::push_viewedge_front(ViewEdge *iViewEdge, bool orientation)
//_Length += (current - previous).norm();
}
- if (!_fedgeB)
+ if (!_fedgeB) {
_fedgeB = (orientation) ? iViewEdge->fedgeB() : iViewEdge->fedgeA();
+ }
}
} /* namespace Freestyle */