help with DXF

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

help with DXF

jon_bondy
Anyone willing to help me get a DXF from InkScape into OpenSCAD,
probably offline from the group?

I took a bit mapped image and used InkScape to create an outline of a lake.

Problem 1: the outline is made of about 12 separate "curves" rather than
1.  When I try to Union, extra lines go all over the place (the Union is
not "smart").

Problem 2: I went to make some minor edits to simplify the shape; and

Problem 3: OpenSCAD keeps telling me that it does not know what a Spline is.

I tried using this approach but failed:

https://repraprip.blogspot.com/2011/05/inkscape-to-openscad-dxf-tutorial.html

I rarely use InkScape at all, so most of this is probably rookie errors

Thanks

Jon


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

nophead
The best way to get a polygon from InkScape into OpenSCAD is to use the OpenSCAD plug-in that generates OpenSCAD polygon code. I think it can be found in Thingiverse.

On 19 May 2018 at 21:12, jon <[hidden email]> wrote:
Anyone willing to help me get a DXF from InkScape into OpenSCAD, probably offline from the group?

I took a bit mapped image and used InkScape to create an outline of a lake.

Problem 1: the outline is made of about 12 separate "curves" rather than 1.  When I try to Union, extra lines go all over the place (the Union is not "smart").

Problem 2: I went to make some minor edits to simplify the shape; and

Problem 3: OpenSCAD keeps telling me that it does not know what a Spline is.

I tried using this approach but failed:

https://repraprip.blogspot.com/2011/05/inkscape-to-openscad-dxf-tutorial.html

I rarely use InkScape at all, so most of this is probably rookie errors

Thanks

Jon


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

Neon22
Inkscape to openscad extension.
https://www.thingiverse.com/thing:1065500

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

cacb
In reply to this post by jon_bondy
On 2018-05-19 22:12, jon wrote:
> Anyone willing to help me get a DXF from InkScape into OpenSCAD,
> probably offline from the group?

Where is your DXF?

Carsten Arnholm

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

cbernhardt
In reply to this post by nophead
The problem is that SPLINE entity in the DXF file is a proprietary AutoCAD
entity.  Only the control points and some other points used by AutoCAD to
define the SPLINE, are listed in the DXF file.  In AutoCAD (at least in the
old version I am using) you cannot "EXPLODE" a SPLINE entity into line and
arc segments, which OpenSCAD understands.  The best you can do with the DXF
file is to edit it and make a list of the control points.  If you look at
the DXF file you will find a series of numbers something like this:
 11
239.6191742034261
 21
687.9629630664632
 31
0.0
 11
400.8514297862043
 21
778.7037046965735
 31
0.0
The number after the "11" is an X coordinate and the number after the "21"
is a Y coordinate of a control point that was used to create the spline.

In the picture below the blue line is the SPLINE and the red lines connect
the control points.
If you can post a link to the DXF file I will see if I can convert it into a
series of short line segments or an AutoCAD POLYLINE, which OpenSCAD can
use.  
<http://forum.openscad.org/file/t1309/spline.jpg>
 



--
Sent from: http://forum.openscad.org/

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

jon_bondy
In reply to this post by cacb
Fred helped me.  In the end, he ignored my poorly crafted DXF and
created his own from my bitmap file.

Thank you, Fred!

Jon


On 5/20/2018 3:10 AM, [hidden email] wrote:
> On 2018-05-19 22:12, jon wrote:
>> Anyone willing to help me get a DXF from InkScape into OpenSCAD,
>> probably offline from the group?
>
> Where is your DXF?
>
> Carsten Arnholm
>
>


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: help with DXF

tsingi
In reply to this post by jon_bondy
Yes, the routine needs to break down curves.  SVG input as well.


On Sat, May 19, 2018 at 4:12 PM, jon <[hidden email]> wrote:
Anyone willing to help me get a DXF from InkScape into OpenSCAD, probably offline from the group?

I took a bit mapped image and used InkScape to create an outline of a lake.

Problem 1: the outline is made of about 12 separate "curves" rather than 1.  When I try to Union, extra lines go all over the place (the Union is not "smart").

Problem 2: I went to make some minor edits to simplify the shape; and

Problem 3: OpenSCAD keeps telling me that it does not know what a Spline is.

I tried using this approach but failed:

https://repraprip.blogspot.com/2011/05/inkscape-to-openscad-dxf-tutorial.html

I rarely use InkScape at all, so most of this is probably rookie errors

Thanks

Jon


_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org



--
"Rumors of my death have been greatly exaggerated."
  -- Jesus Christ

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org