tallakt / bladegen

Generate propeller blades in OpenSCAD
MIT License
14 stars 0 forks source link

Examples broken #2

Closed spreck closed 2 years ago

spreck commented 2 years ago

I'm trying to use the examples given to see how bladegen works, perhaps there are other renaming issues with BOSL2 that are making their way here.

I'm running the following code from the examples:

use <bladegen/bladegen.scad>

INCH_MM = 25.6;

translate([0, 0, 0])   bladegen(pitch = 4 * INCH_MM, diameter = 5 * INCH_MM);
translate([0, 25, 0])  bladegen(pitch = 4 * INCH_MM, diameter = 5 * INCH_MM, outline = rectangular_outline());
translate([0, 50, 0])  bladegen(pitch = 4 * INCH_MM, diameter = 5 * INCH_MM, outline = rectangular_outline(taper_tip = 0.5));
translate([0, 75, 0])  bladegen(pitch = 4 * INCH_MM, diameter = 5 * INCH_MM, outline = elliptical_outline(exponent = 5));
translate([0, 100, 0]) bladegen(pitch = 40, diameter = 100, outline = elliptical_outline(aspect_ratio = 3));
translate([0, 125, 0]) bladegen(pitch = 40, diameter = 100, inner_radius = 0.10);
translate([0, 150, 0]) bladegen(pitch = 40, diameter = 100, ccw = true);
translate([0, 175, 0]) bladegen(pitch = 40, diameter = 100, inner_radius = 0.30, root = ellipse_root(radius = 0.1));
translate([0, 200, 0]) bladegen(pitch = 40, diameter = 100, turbine = true);
translate([0, 225, 0]) bladegen(pitch = 40, diameter = 100, wing_sections = naca_wing_sections([[0.0, 2440], [0.5, 2420], [1.0, 0010]]));
translate([0, 250, 0]) bladegen(pitch = 40, diameter = 100, wing_sections = naca_wing_sections([[0.0, 2440, 8], [0.5, 2420, 8], [1.0, 0010, 0]]));
translate([0, 325, 0]) bladegen(pitch = 40, diameter = 100, inner_radius = 0.15, blades = 5);

And I get the message:

Parsing design (AST generation)...
Compiling design (CSG Tree generation)...
WARNING: Ignoring unknown function 'zip' in file bladegen.scad, line 40 
ERROR: Assertion 'is_list(list)' failed in file ../BOSL2/fnliterals.scad, line 45 
TRACE: called by 'map' in file bladegen.scad, line 40 
TRACE: called by 'naca_wing_sections' in file bladegen, line 15 
TRACE: called by 'bladegen' in file bladegen, line 15 
TRACE: called by 'translate' in file bladegen, line 15 
Compiling design (CSG Products generation)...
Geometries in cache: 40
Geometry cache size in bytes: 340160
CGAL Polyhedrons in cache: 0
CGAL cache size in bytes: 0
Compiling design (CSG Products normalization)...
Normalized tree has 1 elements!
Compile and preview finished.
Total rendering time: 0:00:09.498

Is this "zip" function a dependency from another library? Or did BOSL2 rename that as well?

meee1 commented 2 years ago

for reference yes zip was removed

https://github.com/revarbat/BOSL2/commit/1ec9faec39a4c27137abb7f7fb9eda5446b56744#diff-415febae371d830299e0783dc9582fbeb62bf14d2c1181155bbc56023f62c123L1073

tallakt commented 2 years ago

I added zip in https://github.com/tallakt/bladegen/commit/927d8748541cc025507075907def9bc59cd40aaf

Sorry for the delay