//B. Vandeportaele 2023 use eps=0.0001; resolution=20; //paramètre pour régler le niveau de détail du modèle rendu bords_arrondis=1; //1 pour sphere, 2 pour cylindre ///////////////////// module piece(jeu=0){ rotate([90,0,0]) translate([0,0,-10]) cylinder(h=20,r=15+jeu,$fn=resolution); } ///////////////////// module palette(){ rotate([90,0,0]) union(){ difference(){ minkowski(){ #linear_extrude(height = 400, center = true, convexity = 10, twist =0) polygon([[0,0],[100,0],[100,50],[0,100]], [[0,1,2,3]], convexity = 10); if (bords_arrondis==1){ sphere(r=4,$fn=resolution); } else { //rotate([90,0,0]) cylinder(r=4,h=1,$fn=resolution); } } translate([0,104,0]) rotate([0,0,atan2(-50,100)]) for (b =[1:2]){ for (a =[-4:4]){ echo(a+b*9); // affichage numéro pièce if (((a+b*9) % 4 )!=0){ translate([b*42-5,0,a*42]) //scale([20,20,20]) repere(); piece(0.5); } } } translate([0,104,0]) rotate([0,0,atan2(-50,100)]) hull(){ for (b =[1,2]){ for (a =[-4,4]){ echo(a+b*9); // affichage numéro pièce if (((a+b*9) % 4 )!=0){ translate([b*42-5,9,a*42]) //scale([20,20,20]) repere(); piece(0.5); } } } } } translate([15,10,205-eps]) scale([1.2,2.1,1]) linear_extrude(height = 10, center = true, convexity = 10, twist =0) text("IUT GEII"); } } //////////////////: palette();