Loading

MakerBot Print is our newest print-prepration software, which supports native CAD files and STL assemblies,
allows you to interact with all your printers via the Cloud, and many other exciting new features.

Download Now

Report as inappropriate

I'm trying to extend my repertoire of tools so stuff like this is really useful to demonstrate a singe function or whatever. I wish i know were i could find more demos like this.

You might find this tweaked version of the code useful. It give the torus a smoother outline.
It's an imperfect solution at the moment because the spheres don't re-orientate themselves to the curve of the torus, but u get the idea.

c = 40.5; //angle seed
inc = 10; //increment size
smooth = 24;

color("Fuchsia"){
for(a=[-0:inc:360]){

b1=abs(sin(a)c);
b2=abs(sin(a+inc)
c);

hull(){
//step 1
rotate([0,0,a])
translate([20,0,b1])
rotate([90,0,sin(b1)])
sphere(r=2,$fn=smooth);

//step 2
rotate([0,0,a+inc])
translate([20,0,b2])
rotate([90,0,sin(b2)])
sphere(r=2,$fn=smooth);
}
}
}