Add verbose comments, trying to figure this spiral generation out. Ahhhh!
This commit is contained in:
parent
d8479e33af
commit
56cee0fb3f
|
@ -27,6 +27,22 @@ module spiral (count = 40, start_d = 48, spacing = 2.075) {
|
||||||
|
|
||||||
facetProfile = [[0, 0], [top_offset, -h], [bottom, -h], [bottom, 0]];
|
facetProfile = [[0, 0], [top_offset, -h], [bottom, -h], [bottom, 0]];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Verbose
|
||||||
|
spiralPath = [
|
||||||
|
//for facet number times "count" or number of rotations
|
||||||
|
//create an array containing [ x, y, z] values for path extrude
|
||||||
|
for(t = [0 : $fn * count]) {
|
||||||
|
[
|
||||||
|
//starting radius + (iterator * increment size) * (cosine || sine) of (iterator * fractional angle
|
||||||
|
((start_d / 2) + (t * increment)) * cos(t * angle_i), //x value
|
||||||
|
((start_d / 2) + (t * increment)) * sin(t * angle_i), //y value
|
||||||
|
0 //z value
|
||||||
|
]
|
||||||
|
}
|
||||||
|
];
|
||||||
|
**/
|
||||||
|
|
||||||
|
|
||||||
spiralPath = [ for(t = [0 : $fn * count])
|
spiralPath = [ for(t = [0 : $fn * count])
|
||||||
[((start_d / 2) + (t * increment)) * cos(t * angle_i), ((start_d / 2) + (t * increment)) * sin(t * angle_i), 0] ];
|
[((start_d / 2) + (t * increment)) * cos(t * angle_i), ((start_d / 2) + (t * increment)) * sin(t * angle_i), 0] ];
|
||||||
|
|
|
@ -6,7 +6,9 @@ $fn=FN;
|
||||||
include <../libraries/path_extrude.scad>;
|
include <../libraries/path_extrude.scad>;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Distinction from spiral_3: use of for loop and union to join rotations.
|
* Distinction from spiral_3: use of for loop and union to join rotations. Somehow
|
||||||
|
* got it into my head that this was faster? It does adjust the facet size to the
|
||||||
|
* diameter.
|
||||||
**/
|
**/
|
||||||
|
|
||||||
module spiral (count = 40, start_d = 48, spacing = 2.075) {
|
module spiral (count = 40, start_d = 48, spacing = 2.075) {
|
||||||
|
|
Loading…
Reference in New Issue