[OpenSCAD] Convert from object to polygon/polyhedron.

Adrian H adrianh.bsc at gmail.com
Tue Oct 4 09:09:04 EDT 2016


True that all variables are constants, but there could be an operator that
returns the points.  That wouldn't break that paradigm.  Something like:

_2d = points_edges()
    intersection()
    {
        circle(1, $fn=20);
        square(2);
    }

_3d = points_faces()
    intersection()
    {
        sphere(1, $fn=20);
        cube(2);
    }


Where:

_2d=[ [point0, point1, ...], [ [edge0, ...], [edge1, ...], ...];
_3d=[ [point0, point1, ...], [ [face0, ...], [face1, ...], ...];




On Tue, Oct 4, 2016 at 8:42 AM, Peter Falke <
stempeldergeschichte at googlemail.com> wrote:

> The reason there is no such thing is that OpenSCAD can not change/set the
> variables (set any(!) variable) during  execution.
> But the 2d primitives are eaily written by your self.
> The 3D primitives are doable too, but a little harder.
>
> 2016-10-04 12:51 GMT+02:00 Mark Schafer <mschafer at wireframe.biz>:
>
>> also on thingiverse is an inkscape extension which exports vector objects
>> to openscad format directly:
>> - http://www.thingiverse.com/thing:1065500
>>
>> Yes it would be nice if we could have lines as first class objects in
>> OpenSCAD but for now these tools might help you
>>
>>
>>
>> On 10/4/2016 1:25 PM, Ronaldo wrote:
>>
>>> Yes, there is but not with OpenSCAD language yet. A python code by Neon22
>>> converts AMF files (possibly exported by OpenSCAD) to a text file in the
>>> OpenSCAD polyhedron format. See this discussion:
>>> http://forum.openscad.org/Wrapping-text-around-a-complex-geo
>>> metry-td18145.html#a18156
>>> <http://forum.openscad.org/Wrapping-text-around-a-complex-ge
>>> ometry-td18145.html#a18156>
>>>
>>>
>>>
>>> --
>>> View this message in context: http://forum.openscad.org/Conv
>>> ert-from-object-to-polygon-polyhedron-tp18522p18523.html
>>> Sent from the OpenSCAD mailing list archive at Nabble.com.
>>>
>>> _______________________________________________
>>> OpenSCAD mailing list
>>> Discuss at lists.openscad.org
>>> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
>>>
>>>
>>> -----
>>> No virus found in this message.
>>> Checked by AVG - www.avg.com
>>> Version: 2016.0.7797 / Virus Database: 4656/13139 - Release Date:
>>> 10/03/16
>>>
>>>
>>>
>>
>> _______________________________________________
>> OpenSCAD mailing list
>> Discuss at lists.openscad.org
>> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
>>
>
>
> _______________________________________________
> OpenSCAD mailing list
> Discuss at lists.openscad.org
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscad.org/pipermail/discuss_lists.openscad.org/attachments/20161004/692d76ee/attachment-0002.html>


More information about the Discuss mailing list