summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarius Kintel <marius@kintel.net>2011-09-02 21:33:18 (GMT)
committerMarius Kintel <marius@kintel.net>2011-09-02 21:33:18 (GMT)
commit287c20d2ff1f737acb414b3eda4969356c02c4fe (patch)
tree786e3415fb398dd4017f893bfbff224e0eaf82bc
parent818af2bcfc92f1b1d7cccb6937a481afb7517086 (diff)
Added color-tests
-rw-r--r--testdata/scad/features/color-tests.scad10
-rw-r--r--tests/CMakeLists.txt3
-rw-r--r--tests/regression/cgalpngtest/color-tests-expected.pngbin0 -> 9554 bytes
3 files changed, 12 insertions, 1 deletions
diff --git a/testdata/scad/features/color-tests.scad b/testdata/scad/features/color-tests.scad
new file mode 100644
index 0000000..a87dad3
--- /dev/null
+++ b/testdata/scad/features/color-tests.scad
@@ -0,0 +1,10 @@
+module object() cube([10,10,10]);
+
+translate([12,12,0]) object();
+color([1,0,0]) translate([24,12,0]) object();
+translate([0,12,0]) color([0,1,1]) object();
+color([0,0,1,0.5]) object();
+translate([12,0,0]) color([0,0,1],0.5) object();
+translate([24,0,0]) color(c="Green",alpha=0.2) object();
+translate([-12,12,0]) color() object();
+translate([-12,0,0]) color(alpha=0.5) object();
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt
index 161eade..a985ce7 100644
--- a/tests/CMakeLists.txt
+++ b/tests/CMakeLists.txt
@@ -209,7 +209,8 @@ LIST(APPEND CGALPNGTEST_FILES
${CMAKE_SOURCE_DIR}/../testdata/scad/features/cylinder-tests.scad
${CMAKE_SOURCE_DIR}/../testdata/scad/features/union-tests.scad
${CMAKE_SOURCE_DIR}/../testdata/scad/features/difference-tests.scad
- ${CMAKE_SOURCE_DIR}/../testdata/scad/features/intersection-tests.scad)
+ ${CMAKE_SOURCE_DIR}/../testdata/scad/features/intersection-tests.scad
+ ${CMAKE_SOURCE_DIR}/../testdata/scad/features/color-tests.scad)
#LIST(APPEND CGALPNGTEST_FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
add_cmdline_test(cgalpngtest png ${CGALPNGTEST_FILES})
diff --git a/tests/regression/cgalpngtest/color-tests-expected.png b/tests/regression/cgalpngtest/color-tests-expected.png
new file mode 100644
index 0000000..207fc5b
--- /dev/null
+++ b/tests/regression/cgalpngtest/color-tests-expected.png
Binary files differ
contact: Jan Huwald // Impressum