Update test cases.

master
Torsten Paul 2014-05-03 23:14:45 +02:00
parent d4afb53fee
commit 6e04d33898
118 changed files with 139 additions and 62 deletions

View File

@ -0,0 +1,27 @@
// copy of example001 used for camera tests
module example001()
{
function r_from_dia(d) = d / 2;
module rotcy(rot, r, h) {
rotate(90, rot)
cylinder(r = r, h = h, center = true);
}
difference() {
sphere(r = r_from_dia(size));
rotcy([0, 0, 0], cy_r, cy_h);
rotcy([1, 0, 0], cy_r, cy_h);
rotcy([0, 1, 0], cy_r, cy_h);
}
size = 50;
hole = 25;
cy_r = r_from_dia(hole);
cy_h = r_from_dia(size * 2.5);
}
example001();

View File

@ -833,7 +833,7 @@ configure_file(${CMAKE_SOURCE_DIR}/../testdata/scad/templates/import_dxf-tests-t
file(GLOB FEATURES_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/*.scad)
file(GLOB SCAD_DXF_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/dxf/*.scad)
file(GLOB FUNCTION_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/functions/*.scad)
file(GLOB EXAMPLE_FILES ${CMAKE_SOURCE_DIR}/../examples/*.scad)
file(GLOB EXAMPLE_FILES ${CMAKE_SOURCE_DIR}/../examples/*/*.scad)
list(APPEND ECHO_FILES ${FUNCTION_FILES}
${CMAKE_SOURCE_DIR}/../testdata/scad/features/for-tests.scad
@ -859,7 +859,7 @@ list(APPEND ECHO_FILES ${FUNCTION_FILES}
${CMAKE_SOURCE_DIR}/../testdata/scad/misc/range-tests.scad
${CMAKE_SOURCE_DIR}/../testdata/scad/bugs/empty-stl.scad)
list(APPEND DUMPTEST_FILES ${FEATURES_FILES} ${EXAMPLE_FILES})
list(APPEND DUMPTEST_FILES ${FEATURES_FILES})
list(APPEND DUMPTEST_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/misc/escape-test.scad
${CMAKE_SOURCE_DIR}/../testdata/scad/misc/include-tests.scad
${CMAKE_SOURCE_DIR}/../testdata/scad/misc/use-tests.scad
@ -888,10 +888,6 @@ list(APPEND CGALSTLSANITYTEST_FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/misc/no
# Reenable it when this is improved
disable_tests(opencsgtest_child-background)
# FIXME: This single test takes over an hour to run on a 2.7 GHz P4
disable_tests(opencsgtest_example006 cgalpngtest_example006)
disable_tests(openscad-csgpng_example006 openscad-cgalpng_example006)
# These tests only makes sense in OpenCSG mode
disable_tests(cgalpngtest_child-background
cgalpngtest_highlight-and-background-modifier
@ -907,7 +903,9 @@ disable_tests(cgalpngtest_child-background
set_test_config(Heavy cgalpngtest_rotate_extrude-tests
cgalpngtest_sphere-tests
cgalpngtest_for-nested-tests
cgalpngtest_resize-tests)
cgalpngtest_resize-tests
cgalpngtest_fractal
cgalpngtest_iteration)
# Bugs
@ -1008,6 +1006,7 @@ add_cmdline_test(csgtermtest EXE ${OPENSCAD_BINPATH} ARGS -o SUFFIX term FILES
${CMAKE_SOURCE_DIR}/../testdata/scad/misc/allmodules.scad)
add_cmdline_test(echotest EXE ${OPENSCAD_BINPATH} ARGS -o SUFFIX echo FILES ${ECHO_FILES})
add_cmdline_test(dumptest EXE ${OPENSCAD_BINPATH} ARGS -o SUFFIX csg FILES ${DUMPTEST_FILES})
add_cmdline_test(dumptest-examples EXE ${OPENSCAD_BINPATH} ARGS -o SUFFIX csg FILES ${EXAMPLE_FILES})
add_cmdline_test(cgalpngtest EXE ${OPENSCAD_BINPATH} ARGS --render -o SUFFIX png FILES ${CGALPNGTEST_FILES})
add_cmdline_test(opencsgtest EXE ${OPENSCAD_BINPATH} ARGS -o SUFFIX png FILES ${OPENCSGTEST_FILES})
add_cmdline_test(throwntogethertest EXE ${OPENSCAD_BINPATH} ARGS --preview=throwntogether -o SUFFIX png FILES ${THROWNTOGETHERTEST_FILES})
@ -1043,47 +1042,47 @@ endif()
add_cmdline_test(openscad-imgsize EXE ${OPENSCAD_BINPATH}
ARGS --imgsize 100,100 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-imgstretch EXE ${OPENSCAD_BINPATH}
ARGS --imgsize 500,100 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-imgstretch2 EXE ${OPENSCAD_BINPATH}
ARGS --imgsize 100,500 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-camdist EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=0,0,0,90,0,90,300 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-camrot EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=0,0,0,440,337.5,315,300 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-camtrans EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=100,-20,-10,90,0,90,300 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-camortho EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=100,-20,-10,90,0,90,300 --projection=o -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-cameye EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=60,40,30,0,0,0 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-cameye2 EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=160,140,130,0,0,0 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-cameyeortho EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=160,140,130,0,0,0 --projection=o -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)
add_cmdline_test(openscad-camcenter EXE ${OPENSCAD_BINPATH}
ARGS --imgsize=500,500 --camera=60,40,30,20,10,30 -o
SUFFIX png
FILES ${CMAKE_SOURCE_DIR}/../examples/example001.scad)
FILES ${CMAKE_SOURCE_DIR}/../testdata/scad/features/camera-tests.scad)

View File

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 9.8 KiB

After

Width:  |  Height:  |  Size: 9.8 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

Before

Width:  |  Height:  |  Size: 9.3 KiB

After

Width:  |  Height:  |  Size: 9.3 KiB

View File

Before

Width:  |  Height:  |  Size: 5.7 KiB

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

Before

Width:  |  Height:  |  Size: 7.4 KiB

After

Width:  |  Height:  |  Size: 7.4 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 21 KiB

After

Width:  |  Height:  |  Size: 21 KiB

View File

Before

Width:  |  Height:  |  Size: 7.8 KiB

After

Width:  |  Height:  |  Size: 7.8 KiB

View File

Before

Width:  |  Height:  |  Size: 6.8 KiB

After

Width:  |  Height:  |  Size: 6.8 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 6.8 KiB

After

Width:  |  Height:  |  Size: 6.8 KiB

View File

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

View File

Before

Width:  |  Height:  |  Size: 36 KiB

After

Width:  |  Height:  |  Size: 36 KiB

View File

Before

Width:  |  Height:  |  Size: 8.9 KiB

After

Width:  |  Height:  |  Size: 8.9 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 8.2 KiB

After

Width:  |  Height:  |  Size: 8.2 KiB

View File

@ -1,16 +1,17 @@
group() {
group();
intersection() {
linear_extrude(height = 100, center = true, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "advance_intersection.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = true, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "advance_intersection.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = true, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "advance_intersection.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,4 +1,5 @@
group() {
group();
difference() {
group() {
cube(size = [65, 28, 28], center = true);
@ -17,7 +18,7 @@ group() {
}
group() {
multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
import(file = "chopped_blocks.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -36,7 +37,7 @@ group() {
}
group() {
multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
import(file = "chopped_blocks.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -55,7 +56,7 @@ group() {
}
group() {
multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
import(file = "chopped_blocks.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -74,7 +75,7 @@ group() {
}
group() {
multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
import(file = "chopped_blocks.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,8 +1,11 @@
group() {
group();
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) {
group() {
difference() {
rotate_extrude(file = "example007.dxf", layer = "dorn", origin = [0, 0], scale = 1, convexity = 3, $fn = 0, $fa = 12, $fs = 2);
rotate_extrude(convexity = 3, $fn = 0, $fa = 12, $fs = 2) {
import(file = "cut_view.dxf", layer = "dorn", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
group() {
@ -10,7 +13,7 @@ group() {
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "cut_view.dxf", layer = "cutout1", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -18,7 +21,7 @@ group() {
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = false, convexity = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "cut_view.dxf", layer = "cutout2", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -32,7 +35,7 @@ group() {
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "cut_view.dxf", layer = "cutout1", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -40,7 +43,7 @@ group() {
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) {
linear_extrude(height = 100, center = false, convexity = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "cut_view.dxf", layer = "cutout2", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,4 +1,5 @@
group() {
group();
multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
group() {
linear_extrude(height = 0.5, center = true, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {

View File

@ -1,4 +1,5 @@
group() {
group();
multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
group() {
linear_extrude(height = 100, center = false, convexity = 8, twist = 411.429, slices = 34, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
difference() {
cube(size = [30, 30, 30], center = true);

View File

@ -0,0 +1,23 @@
group() {
group();
group() {
difference() {
sphere($fn = 0, $fa = 12, $fs = 2, r = 25);
group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
cylinder($fn = 0, $fa = 12, $fs = 2, h = 62.5, r1 = 12.5, r2 = 12.5, center = true);
}
}
group() {
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
cylinder($fn = 0, $fa = 12, $fs = 2, h = 62.5, r1 = 12.5, r2 = 12.5, center = true);
}
}
group() {
multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) {
cylinder($fn = 0, $fa = 12, $fs = 2, h = 62.5, r1 = 12.5, r2 = 12.5, center = true);
}
}
}
}
}

View File

@ -0,0 +1,26 @@
group() {
group();
% linear_extrude(height = 22, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "fan_view.dxf", layer = "body", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
% group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) {
linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "fan_view.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -12], [0, 0, 0, 1]]) {
linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "fan_view.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
intersection() {
linear_extrude(height = 20, center = true, convexity = 10, twist = -57.5288, slices = 4, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "fan_view.dxf", layer = "fan_top", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
rotate_extrude(convexity = 10, $fn = 0, $fa = 12, $fs = 2) {
import(file = "fan_view.dxf", layer = "fan_side", origin = [0, -40], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
multmatrix([[1, 0, 0, -100], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) {
cylinder($fn = 0, $fa = 12, $fs = 2, h = 45, r1 = 6, r2 = 2, center = false);

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
difference() {
multmatrix([[1, 0, 0, -35], [0, 1, 0, -35], [0, 0, 1, 0], [0, 0, 0, 1]]) {
@ -25,6 +26,6 @@ group() {
}
}
}
import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 2, convexity = 6, $fn = 0, $fa = 12, $fs = 2);
import(file = "flat_body.dxf", layer = "body", origin = [0, 0], scale = 2, convexity = 6, $fn = 0, $fa = 12, $fs = 2);
}
}

View File

@ -1,4 +1,5 @@
group() {
group();
difference() {
multmatrix([[0.81649658092, 0.40824829046, 0.40824829046, 0], [0, 0.70710678118, -0.70710678118, 0], [-0.57735026919, 0.57735026919, 0.57735026919, 0], [0, 0, 0, 1]]) {
group() {

View File

@ -1,4 +1,5 @@
group() {
group();
intersection() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
cube(size = [100, 20, 20], center = true);

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
intersection() {
difference() {

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
difference() {
cube(size = [100, 100, 100], center = true);

View File

@ -1,4 +1,5 @@
group() {
group();
linear_extrude(height = 20, center = false, convexity = 1, scale = [0.5, 0.5], $fn = 40, $fa = 12, $fs = 2) {
offset(delta = 10, join_type = round, miter_limit = 2, $fn = 40, $fa = 12, $fs = 2) {
square(size = [50, 50], center = true);

View File

@ -1,3 +1,4 @@
group() {
group();
polyhedron(points = [[10, 0, 0], [0, 10, 0], [-10, 0, 0], [0, -10, 0], [0, 0, 10]], faces = [[0, 1, 2, 3], [4, 1, 0], [4, 2, 1], [4, 3, 2], [4, 0, 3]], convexity = 1);
}

View File

@ -1,4 +1,5 @@
group() {
group();
multmatrix([[1, 0, 0, -15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
group() {
group() {

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
group() {
group() {

View File

@ -1,9 +1,10 @@
group() {
group();
difference() {
sphere($fn = 0, $fa = 12, $fs = 2, r = 20);
multmatrix([[1, 0, 0, -2.92], [0, 1, 0, 0.5], [0, 0, 1, 20], [0, 0, 0, 1]]) {
multmatrix([[-1, 0, 0, 0], [0, 1, 0, 0], [0, 0, -1, 0], [0, 0, 0, 1]]) {
import(file = "example012.stl", layer = "", origin = [0, 0], scale = 1, convexity = 5, $fn = 0, $fa = 12, $fs = 2);
import(file = "sphere.stl", layer = "", origin = [0, 0], scale = 1, convexity = 5, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,8 +1,9 @@
group() {
group();
intersection() {
surface(file = "example010.dat", center = true, invert = false);
surface(file = "surface.dat", center = true, invert = false);
multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) {
surface(file = "example010.dat", center = true, invert = false);
surface(file = "surface.dat", center = true, invert = false);
}
}
}

View File

@ -1,22 +1,23 @@
group() {
group();
difference() {
intersection() {
multmatrix([[1, 0, 0, -25], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) {
linear_extrude(height = 50, center = false, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example008.dxf", layer = "G", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "text.dxf", layer = "G", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
multmatrix([[1, 0, 0, 0], [0, 0, -1, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, -25], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) {
linear_extrude(height = 50, center = false, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example008.dxf", layer = "E", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "text.dxf", layer = "E", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, -125], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) {
linear_extrude(height = 50, center = false, convexity = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example008.dxf", layer = "B", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "text.dxf", layer = "B", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
@ -24,13 +25,13 @@ group() {
intersection() {
multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -26], [0, 0, 0, 1]]) {
linear_extrude(height = 52, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "text.dxf", layer = "X", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) {
multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -26], [0, 0, 0, 1]]) {
linear_extrude(height = 52, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
import(file = "text.dxf", layer = "X", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -120], [0, 0, 0, 1]]) {
difference() {

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, -150], [0, 0, 1, 0], [0, 0, 0, 1]]) {
group() {

View File

@ -1,4 +1,5 @@
group() {
group();
group();
group();
group() {

View File

@ -1,4 +1,5 @@
group() {
group();
group() {
difference() {
union() {

View File

@ -1,23 +0,0 @@
group() {
% linear_extrude(height = 22, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
% group() {
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) {
linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -12], [0, 0, 0, 1]]) {
linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
}
}
intersection() {
linear_extrude(height = 20, center = true, convexity = 10, twist = -57.5288, slices = 4, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) {
import(file = "example009.dxf", layer = "fan_top", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2);
}
rotate_extrude(file = "example009.dxf", layer = "fan_side", origin = [0, -40], scale = 1, convexity = 10, $fn = 0, $fa = 12, $fs = 2);
}
}

View File

Before

Width:  |  Height:  |  Size: 9.8 KiB

After

Width:  |  Height:  |  Size: 9.8 KiB

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 20 KiB

After

Width:  |  Height:  |  Size: 20 KiB

View File

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 30 KiB

After

Width:  |  Height:  |  Size: 30 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

Before

Width:  |  Height:  |  Size: 8.3 KiB

After

Width:  |  Height:  |  Size: 8.3 KiB

View File

Before

Width:  |  Height:  |  Size: 4.9 KiB

After

Width:  |  Height:  |  Size: 4.9 KiB

View File

Before

Width:  |  Height:  |  Size: 5.7 KiB

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

Before

Width:  |  Height:  |  Size: 8.5 KiB

After

Width:  |  Height:  |  Size: 8.5 KiB

View File

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 7.1 KiB

After

Width:  |  Height:  |  Size: 7.1 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 7.2 KiB

After

Width:  |  Height:  |  Size: 7.2 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

Before

Width:  |  Height:  |  Size: 29 KiB

After

Width:  |  Height:  |  Size: 29 KiB

View File

Before

Width:  |  Height:  |  Size: 9.3 KiB

After

Width:  |  Height:  |  Size: 9.3 KiB

View File

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

View File

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 19 KiB

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

Before

Width:  |  Height:  |  Size: 8.8 KiB

After

Width:  |  Height:  |  Size: 8.8 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 25 KiB

After

Width:  |  Height:  |  Size: 25 KiB

View File

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

View File

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

View File

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

View File

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

Before

Width:  |  Height:  |  Size: 3.4 KiB

After

Width:  |  Height:  |  Size: 3.4 KiB

View File

Before

Width:  |  Height:  |  Size: 3.8 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 16 KiB

After

Width:  |  Height:  |  Size: 16 KiB

View File

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

View File

Before

Width:  |  Height:  |  Size: 6.8 KiB

After

Width:  |  Height:  |  Size: 6.8 KiB

View File

Before

Width:  |  Height:  |  Size: 26 KiB

After

Width:  |  Height:  |  Size: 26 KiB

View File

Before

Width:  |  Height:  |  Size: 38 KiB

After

Width:  |  Height:  |  Size: 38 KiB

View File

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Some files were not shown because too many files have changed in this diff Show More