openscad

Evaluating Environment Variables in VS Code Extension

五迷三道 提交于 2020-12-13 18:52:37
问题 I'm developing an extension in VS Code to add language support for OpenSCAD (Script-based 3D modeling program). Currently, I have been working on a way to open / preview a file in OpenSCAD from VS Code, which I have been able to do successfully using my own preview manager. My issue is that I want to add configurable naming formats when exporting an OpenSCAD file that use environment variables similar to those used in the tasks.json file. More info can be found here: https://code.visualstudio

3D打印开放工具链-开源而且免费

陌路散爱 提交于 2020-04-07 13:15:58
开源的3D打印开放工具链 : 3D打印机 :DreamMaker,由DFRobot生产,这是中国很早做创客产品的机构。是实现同样精度的成本最低的产品了,非常酷,而且易于学习。 基础建模软件 :OpenSCAD,以程序的方式进行建模,思路独到,使用方便。背后是开发了将近二十年的CGAL三维几何布尔运算库。如果不想用SolidEdge这样的昂贵的庞然大物,OpenSCAD是个很好的选择。 二维草图软件 :inkscape,名气很大的哦。可以与CorelDraw相比较的草图绘制工具。 图像处理软件 :GIMP,这个不用说了。功能堪比Photoshop,但是开源、免费的。 三维建模软件 :Blender,快速窜红的三维软件,不亚于昂贵的Maya。 模型打印软件 :Cura,大名鼎鼎的Ultimaker出的,很好用。 由于不同软件使用自己的文件存储格式,要制作完成一个模型,需要在几种文件格式之间多次转换(现在还没有完全集成化的工具平台,只能这样了哦!)。 scad/3DS\.X\DXF,模型文件:很多三维建模软件都输出这些格式,比较通用。但是3D打印需要明确模型内部哪些是空洞、哪些是填充,还有就是连接处如果是实的,一定要确保拓扑连接上,不仅仅是视觉上是连在一起的,都需要进行处理。 STL,切片文件:很多建模软件可以直接输出STL文件了,但不同软件的效果是不一样的,需要自己试试找出好使的

Wrap an image around a cylinder

扶醉桌前 提交于 2020-01-15 06:13:29
问题 Someone asked me recently if I could print a bracelet with a custom image engraved on its side. To me, the problem is simple: I have a 2d cartesian system (x,y) that expresses the points of the vectorized image the person sent me. I want to treat these as a 3d cylindrical system (theta, r, z') where r is constant. Finally, I want to convert this 3d cylindrical system to a 3d cartesian system (x',y',z') in the usual way. So: z' = y y' = r cos(x) x' = r sin(x) The problem is I don't know how to

Wrap an image around a cylinder

回眸只為那壹抹淺笑 提交于 2020-01-15 06:12:48
问题 Someone asked me recently if I could print a bracelet with a custom image engraved on its side. To me, the problem is simple: I have a 2d cartesian system (x,y) that expresses the points of the vectorized image the person sent me. I want to treat these as a 3d cylindrical system (theta, r, z') where r is constant. Finally, I want to convert this 3d cylindrical system to a 3d cartesian system (x',y',z') in the usual way. So: z' = y y' = r cos(x) x' = r sin(x) The problem is I don't know how to

Wrap an image around a cylinder

家住魔仙堡 提交于 2020-01-15 06:11:25
问题 Someone asked me recently if I could print a bracelet with a custom image engraved on its side. To me, the problem is simple: I have a 2d cartesian system (x,y) that expresses the points of the vectorized image the person sent me. I want to treat these as a 3d cylindrical system (theta, r, z') where r is constant. Finally, I want to convert this 3d cylindrical system to a 3d cartesian system (x',y',z') in the usual way. So: z' = y y' = r cos(x) x' = r sin(x) The problem is I don't know how to

how to save data in stl file after python solid processing?

不打扰是莪最后的温柔 提交于 2019-12-24 18:49:41
问题 I need to process openscad programs on python. I use solid library (https://solidpython.readthedocs.io/en/latest/index.html) but I haven't found any method to save data after process. Example from solid import * d = difference()( cube(10), sphere(15) ) I need to save d variable to stl file. How to do this? And if there's better library, I need advice what library better to use. 回答1: You need openscad to export data as stl-file. You can do this from python-code: from solid import * # to run

Java library for creating 3d-objects for 3d printing

半城伤御伤魂 提交于 2019-12-21 04:14:39
问题 I am looking for a java library to create 3d-geometries and then convert that to .stl files so I can 3d print my object using a 3d printer. I can imagine using a 3d-graphics object where one can draw the same like on a graphics2d object: Buffered3DObject obj = new Buffered3DObject(200,200,200, Unit.MM); Graphics3D g3 = obj.getGraphics(); Stroke3d stroke = new Stroke(3); g3.setStroke(stroke); g3.drawpipe(x1,y1,z1,x2,y2,z2); obj.exportToSTL("filename.stl"); Ok, I am just making up code :). But

OpenSCAD how to access a value within a Matrix

六眼飞鱼酱① 提交于 2019-12-12 02:55:50
问题 I'm trying to either access and assign the values assigned to coordinates through the forloop to their single variables as below, or at least be able to access the values separately in the Matrix. for ( coordinates = [ [ 15, 15, 2], [ 15, -15, 2], [ -15, -15, 2], [ -15, 15, 2] ]) { x = coordinates[0]; y = coordinates[1]; z = coordinates[2]; translate([x+4, y, z]){ cube([x,y,z]); } } 回答1: First off, standard variables are set at compile-time in OpenSCAD, not run-time (official documentation

How can I render a dxf file with Sphere in OpenSCAD

旧巷老猫 提交于 2019-12-11 15:27:30
问题 I have a rendering problem about importing dxf file. Rendering success: Use linear_extrude() for a dxf file and display a sphere. Only use rotate_extrude() for a dxf file. Rendering fail: Use rotate_extrude() for a dxf file and display a sphere. Here is my source code: module loadFile() { rotate_extrude() import("import_exercise.dxf"); } module loadSphere() { translate([0,0,-30]) sphere(10); } loadFile(); loadSphere(); Here is the error message: ERROR: CGAL error in CGAL_Nef_polyhedron3():

OpenSCAD三维造型设计语言

孤街醉人 提交于 2019-12-05 10:25:35
cube Creates a cube at the origin of the coordinate system. When center is true the cube will be centered on the origin, otherwise it is created in the first octant. The argument names are optional if the arguments are given in the same order as specified in the parameters Parameters size Decimal or 3 value array. If a single number is given, the result will be a cube with sides of that length. If a 3 value array is given, then the values will correspond to the lengths of the X, Y, and Z sides. Default value is 1. center Boolean. This determines the positioning of the object. If true, object