Hallo Foraner! Habe momentan ein Projekt mit OpenSCAD, das ein Module nach einem iterativem Muster aneinanderreiht. Also der Wert eines for() Durchlaufs hängt vom letzten Durchlauf ab. aber das funktioniert so nicht in OpenSCAD:
"for() is not an exception to the rule about variables having only one value within a scope. Each evaluation is given its own scope, allowing any variables to have unique values. No, you still can't do a=a+1;
Remember this is not an iterative language, the for() does not loop in the programmatic sense, it builds a tree of objects one branch for each item in the range/vector, inside each branch the 'variable' is a specific and separate instantiation or scope."
Ich habe die Berechnung separat mit PureBasic erstellt und getestet. Einen ersten Prototypen habe ich erstellt, indem ich die berechneten Werte cit copy/paste übertragen habe. Schön ist anders.
Was wäre die beste/sauberste Möglichkeit, das Problem zu lösen? Ich sehe gerade nur eine Möglichkeit:
Erstellen einer Datei der einzelnen Module-Aufrufe mit PureBasic und include in OpenSCAD
Danke für Ideen!
Gruss Chregu


