diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/CMakeLists.txt | 1 | ||||
-rw-r--r-- | tests/cgalpngtest.cc | 16 | ||||
-rw-r--r-- | tests/cgalstlsanitytest.cc | 2 | ||||
-rw-r--r-- | tests/cgaltest.cc | 2 | ||||
-rw-r--r-- | tests/regression/cgalpngtest/control-hull-dimension-expected.png | bin | 0 -> 6301 bytes | |||
-rw-r--r-- | tests/regression/dumptest/control-hull-dimension-expected.txt | 5 | ||||
-rw-r--r-- | tests/regression/opencsgtest/control-hull-dimension-expected.png | bin | 0 -> 6868 bytes | |||
-rw-r--r-- | tests/regression/throwntogethertest/control-hull-dimension-expected.png | bin | 0 -> 6868 bytes | |||
-rwxr-xr-x | tests/test_pretty_print.py | 6 |
9 files changed, 18 insertions, 14 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 18f4469..87e5319 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -773,7 +773,6 @@ set_test_config(Heavy opencsgtest_minkowski3-tests cgalpngtest_minkowski3-tests cgalpngtest_for-tests cgalpngtest_for-nested-tests - cgalpngtest_difference-tests cgalpngtest_intersection-tests) foreach(FILE ${EXAMPLE_FILES}) diff --git a/tests/cgalpngtest.cc b/tests/cgalpngtest.cc index 08e539e..56861c6 100644 --- a/tests/cgalpngtest.cc +++ b/tests/cgalpngtest.cc @@ -153,30 +153,30 @@ int main(int argc, char **argv) exit(1); } - CGALRenderer cgalRenderer(N); - + CGALRenderer cgalRenderer(N); + BoundingBox bbox; if (cgalRenderer.polyhedron) { CGAL::Bbox_3 cgalbbox = cgalRenderer.polyhedron->bbox(); bbox = BoundingBox(Vector3d(cgalbbox.xmin(), cgalbbox.ymin(), cgalbbox.zmin()), - Vector3d(cgalbbox.xmax(), cgalbbox.ymax(), cgalbbox.zmax())); + Vector3d(cgalbbox.xmax(), cgalbbox.ymax(), cgalbbox.zmax())); } else if (cgalRenderer.polyset) { bbox = cgalRenderer.polyset->getBoundingBox(); } - + Vector3d center = getBoundingCenter(bbox); double radius = getBoundingRadius(bbox); - + Vector3d cameradir(1, 1, -0.5); Vector3d camerapos = center - radius*2*cameradir; csgInfo.glview->setCamera(camerapos, center); - - + + csgInfo.glview->setRenderer(&cgalRenderer); csgInfo.glview->paintGL(); csgInfo.glview->save(outfile); - + delete root_node; delete root_module; diff --git a/tests/cgalstlsanitytest.cc b/tests/cgalstlsanitytest.cc index 137f626..52cfb41 100644 --- a/tests/cgalstlsanitytest.cc +++ b/tests/cgalstlsanitytest.cc @@ -129,7 +129,7 @@ int main(int argc, char **argv) CGAL_Nef_polyhedron N = cgalevaluator.evaluateCGALMesh(*root_node); current_path(original_path); - if (!N.empty()) { + if (!N.isNull()) { std::ofstream outfile; outfile.open(outfilename); diff --git a/tests/cgaltest.cc b/tests/cgaltest.cc index e4761db..b546286 100644 --- a/tests/cgaltest.cc +++ b/tests/cgaltest.cc @@ -122,7 +122,7 @@ int main(int argc, char **argv) CGAL_Nef_polyhedron N = cgalevaluator.evaluateCGALMesh(*root_node); current_path(original_path); - if (!N.empty()) { + if (!N.isNull()) { export_stl(&N, std::cout); } diff --git a/tests/regression/cgalpngtest/control-hull-dimension-expected.png b/tests/regression/cgalpngtest/control-hull-dimension-expected.png Binary files differnew file mode 100644 index 0000000..ceeaf54 --- /dev/null +++ b/tests/regression/cgalpngtest/control-hull-dimension-expected.png diff --git a/tests/regression/dumptest/control-hull-dimension-expected.txt b/tests/regression/dumptest/control-hull-dimension-expected.txt new file mode 100644 index 0000000..be2e4ee --- /dev/null +++ b/tests/regression/dumptest/control-hull-dimension-expected.txt @@ -0,0 +1,5 @@ + hull() { + circle($fn = 0, $fa = 12, $fs = 2, r = 1); + group(); + } + diff --git a/tests/regression/opencsgtest/control-hull-dimension-expected.png b/tests/regression/opencsgtest/control-hull-dimension-expected.png Binary files differnew file mode 100644 index 0000000..52d11c1 --- /dev/null +++ b/tests/regression/opencsgtest/control-hull-dimension-expected.png diff --git a/tests/regression/throwntogethertest/control-hull-dimension-expected.png b/tests/regression/throwntogethertest/control-hull-dimension-expected.png Binary files differnew file mode 100644 index 0000000..52d11c1 --- /dev/null +++ b/tests/regression/throwntogethertest/control-hull-dimension-expected.png diff --git a/tests/test_pretty_print.py b/tests/test_pretty_print.py index 8c57f1c..a2a04ed 100755 --- a/tests/test_pretty_print.py +++ b/tests/test_pretty_print.py @@ -1,8 +1,8 @@ #!/usr/bin/python -# test_pretty_print copyright 2012 don bright. released under the GPL 2, or -# later, as described in the file named 'COPYING' in OpenSCAD's project root. -# permission to change this license is given to Marius Kintel & Clifford Wolf +# test_pretty_print by don bright 2012. Copyright assigned to Marius Kintel and +# Clifford Wolf 2012. Released under the GPL 2, or later, as described in +# the file named 'COPYING' in OpenSCAD's project root. # # This program 'pretty prints' the ctest output, namely |