Please visit http://OpenSCAD.DIY3DTech.com for more information on this and many other projects! As in this episode we will be looking at an application which will allow us to take an image (2D) and render it in Open SCAD as a polygon point cloud and do some amazing things with it!
Open-SCAD Contour Application Download:
http://dpruimboom.magix.net/public/
Apologies as wordpress could not handle the point cloud from the Einstein picture so we will have to figure another way to link it in.
Poly Test (Rocket):
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
/* Open SCAD Name.: poly_test.scad * Copyright (c)..: 2016 www.DIY3DTech.com * * Creation Date..: 08/12/2016 * Description....: poly test of rocket image * * Rev 1: Develop Model * Rev 2: * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. */ /*------------------Customizer View-------------------*/ // preview[view:north, tilt:top] /*---------------------Parameters---------------------*/ step = 45; //define number of iterations 360/step extrude_height = 1; //thickness of extrude /*-----------------------Execute----------------------*/ for (i=[1:step:360]){ rotate ([0,i,0]) linear_extrude(height = 1, center = true, convexity = 10, twist = 0, slices = 20, scale = 1.0) rocket(); }//end for loop /*-----------------------Modules----------------------*/ module rocket(){ polygon(points=[[-4.427536,100.3696],[3.572464,100.3696],[7.572464,96.36957],[8.572464,94.36957],[17.57246,76.36957],[21.57246,67.36957],[22.57246,63.36957],[23.57246,61.36957],[24.57246,57.36957],[25.57246,55.36957],[26.57246,51.36957],[27.57246,47.36957],[28.57246,43.36957],[28.57246,41.36957],[29.57246,39.36957],[29.57246,36.36957],[30.57246,34.36957],[30.57246,28.36957],[31.57246,26.36957],[31.57246,14.36957],[32.57246,12.36957],[32.57246,-1.630432],[31.57246,-3.630432],[31.57246,-15.63043],[30.57246,-17.63043],[30.57246,-22.63043],[29.57246,-24.63043],[29.57246,-28.63043],[28.57246,-30.63043],[28.57246,-32.63043],[31.57246,-36.63043],[32.57246,-38.63043],[34.57246,-40.63043],[35.57246,-42.63043],[39.57246,-47.63043],[40.57246,-49.63043],[42.57246,-51.63043],[43.57246,-53.63043],[47.57246,-58.63043],[48.57246,-60.63043],[51.57246,-64.63043],[51.57246,-120.6304],[49.57246,-119.6304],[41.57246,-111.6304],[40.57246,-109.6304],[17.57246,-86.63043],[15.57246,-87.63043],[15.57246,-93.63043],[-17.42754,-93.63043],[-17.42754,-87.63043],[-19.42754,-86.63043],[-43.42754,-110.6304],[-44.42754,-112.6304],[-52.42754,-120.6304],[-53.42754,-120.6304],[-53.42754,-64.63043],[-51.42754,-62.63043],[-50.42754,-60.63043],[-46.42754,-55.63043],[-45.42754,-53.63043],[-41.42754,-48.63043],[-40.42754,-46.63043],[-36.42754,-41.63043],[-35.42754,-39.63043],[-33.42754,-37.63043],[-32.42754,-35.63043],[-29.42754,-31.63043],[-29.42754,-27.63043],[-30.42754,-25.63043],[-30.42754,-20.63043],[-31.42754,-18.63043],[-31.42754,-11.63043],[-32.42754,-9.630432],[-32.42754,24.36957],[-31.42754,26.36957],[-31.42754,33.36957],[-30.42754,35.36957],[-30.42754,39.36957],[-29.42754,41.36957],[-29.42754,44.36957],[-28.42754,46.36957],[-28.42754,48.36957],[-27.42754,50.36957],[-27.42754,52.36957],[-26.42754,54.36957],[-26.42754,56.36957],[-25.42754,58.36957],[-24.42754,62.36957],[-23.42754,64.36957],[-20.42754,71.36957],[-15.42754,82.36957],[-12.42754,88.36957],[-8.427536,95.36957],[-6.427536,97.36957],[-5.427536,99.36957],[5.572464,43.36957],[3.572464,44.36957],[-4.427536,44.36957],[-9.427536,40.36957],[-11.42754,38.36957],[-12.42754,34.36957],[-13.42754,32.36957],[-12.42754,28.36957],[-10.42754,24.36957],[-6.427536,20.36957],[-4.427536,20.36957],[-2.427536,19.36957],[3.572464,19.36957],[7.572464,22.36957],[9.572464,23.36957],[10.57246,25.36957],[11.57246,27.36957],[12.57246,31.36957],[12.57246,35.36957],[9.572464,40.36957],[6.572464,43.36957],[5.572464,2.369568],[3.572464,3.369568],[-4.427536,3.369568],[-9.427536,-0.6304321],[-11.42754,-2.630432],[-12.42754,-6.630432],[-13.42754,-8.630432],[-12.42754,-12.63043],[-10.42754,-16.63043],[-6.427536,-20.63043],[-4.427536,-20.63043],[-2.427536,-21.63043],[3.572464,-21.63043],[7.572464,-18.63043],[9.572464,-17.63043],[10.57246,-15.63043],[11.57246,-13.63043],[12.57246,-9.630432],[12.57246,-5.630432],[9.572464,-0.6304321],[7.572464,1.369568],[6.572464,1.369568]],paths=[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94],[95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115],[116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137]]); }//end module /*----------------------End Code----------------------*/ |
More Ideas!
Open SCAD – Scale Guides!
Open SCAD – Introduction Part 1 for New Users!
Open SCAD – Universal Base Designer!