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:
authorTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>2014-04-03 09:58:14 +0400
committerTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>2014-04-03 09:59:19 +0400
commit75c0ced840aa0efba6e354266b946c02b0c1d939 (patch)
tree5db8b727b6d5452ee7c78abe70f1ae565c05616a /source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
parentc6d85407d47c201e3af6fe12ed2b204a5e5fc0a0 (diff)
Freestyle: Fix for debug information about sweep line intersection detection.
Vertices of two edges were swapped by mistake. Also fixed indentation and added a couple of debug prints to make it easier to visualize the lines using Matlab.
Diffstat (limited to 'source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp')
-rw-r--r--source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp b/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
index 691c7a4afe4..6f4f1df4b47 100644
--- a/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
+++ b/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
@@ -2332,14 +2332,16 @@ void ViewMapBuilder::ComputeSweepLineIntersections(ViewMap *ioViewMap, real epsi
if ((Ta < -epsilon) || (Ta > 1 + epsilon) || (Tb < -epsilon) || (Tb > 1 + epsilon)) {
printf("ta %.12e\n", ta);
printf("tb %.12e\n", tb);
- printf("a1 %e, %e -- b1 %e, %e\n", a1[0], a1[1], b1[0], b1[1]);
- printf("a2 %e, %e -- b2 %e, %e\n", a2[0], a2[1], b2[0], b2[1]);
+ printf("a1 %e, %e -- a2 %e, %e\n", a1[0], a1[1], a2[0], a2[1]);
+ printf("b1 %e, %e -- b2 %e, %e\n", b1[0], b1[1], b2[0], b2[1]);
+ //printf("line([%e, %e], [%e, %e]);\n", a1[0], a2[0], a1[1], a2[1]);
+ //printf("line([%e, %e], [%e, %e]);\n", b1[0], b2[0], b1[1], b2[1]);
if ((Ta < -epsilon) || (Ta > 1 + epsilon))
- printf("Ta %.12e\n", Ta);
+ printf("Ta %.12e\n", Ta);
if ((Tb < -epsilon) || (Tb > 1 + epsilon))
- printf("Tb %.12e\n", Tb);
- printf("A1 %e, %e, %e -- B1 %e, %e, %e\n", A1[0], A1[1], A1[2], B1[0], B1[1], B1[2]);
- printf("A2 %e, %e, %e -- B2 %e, %e, %e\n", A2[0], A2[1], A2[2], B2[0], B2[1], B2[2]);
+ printf("Tb %.12e\n", Tb);
+ printf("A1 %e, %e, %e -- A2 %e, %e, %e\n", A1[0], A1[1], A1[2], A2[0], A2[1], A2[2]);
+ printf("B1 %e, %e, %e -- B2 %e, %e, %e\n", B1[0], B1[1], B1[2], B2[0], B2[1], B2[2]);
}
}
#endif