Rendering DXFs from Inkscape

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

Rendering DXFs from Inkscape

GamerDarling
This post has NOT been accepted by the mailing list yet.
Hey guys, I'm having trouble getting Openscad to process DXF files I make in Inkscape. I want to make some new cookie cutters, using the code here: http://www.thingiverse.com/thing:28882 but openscad keeps giving me errors about intersecting lines, and that doesn't make any sense to me because I'm literally going as simple as drawing a circle in inkscape, converting object to a path(so it becomes a square), selecting the edit paths by nodes tool, selecting the whole object, make selected segments lines, and exporting to dxf with LWPOLYLINE as type of line output. I'm pretty sure I'm missing something basic.

I've been following this tutorial to a T: http://repraprip.blogspot.co.nz/2011...-tutorial.html and no dice even just getting it to extrude ten px using the code in the blog post. I get the same set of errors as with the cookie cutter code, so I'm betting it has to do with the DXF file I'm creating, but I have no idea what to change.

Has anybody tinkered with getting openscad to take DXF files from inkscape? What steps did you use?
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

kintel
Administrator
The tutorial works perfectly for me.
Could it be that you're using a really old version of OpenSCAD?
I would recommend at least OpenSCAD-2014.03, and preferably the latest development snapshot.

 -Marius
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

GamerDarling
This post has NOT been accepted by the mailing list yet.
I actually just reinstalled this morning using that version, and still no dice. The DXF file of the pi sign included in the thing on thingiverse is functioning, which is what has me thinking it's something with the file I'm creating for the script. The export from inkscape that I'm getting is an r14 instead of an r12, do you know which file type you're getting out of inkscape by chance? 

On Sun, Mar 1, 2015 at 10:55 AM, kintel [via OpenSCAD] <[hidden email]> wrote:
The tutorial works perfectly for me.
Could it be that you're using a really old version of OpenSCAD?
I would recommend at least OpenSCAD-2014.03, and preferably the latest development snapshot.

 -Marius



If you reply to this email, your message will be added to the discussion below:
http://forum.openscad.org/Rendering-DXFs-from-Inkscape-tp11789p11791.html
To unsubscribe from Rendering DXFs from Inkscape, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

kintel
Administrator
Make sure you're exporting as a "Desktop Cutting Plotter" file, not an "AutoCAD DXF" file.

 -Marius
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

GamerDarling
This post has NOT been accepted by the mailing list yet.
Here's the save screen: http://screencast.com/t/O2tpsgRv
and here's what I'm choosing on the options screen that pops up after that: http://screencast.com/t/O2tpsgRv

When you did it and it worked, what were the exact steps you followed? For me the following steps aren't working: 

1- Draw circle
2- Hit ctrl+shift+C
3- Select edit by nodes tool
4- Hit Ctrl+a 
5- Click the New Nodes button 2x
6- Click turn selected segments into lines
7- Save file as w/selections shown

Does that match your process, or am I missing any steps? I feel like this is going to end up being something dead simple. 

On Sun, Mar 1, 2015 at 11:13 AM, kintel [via OpenSCAD] <[hidden email]> wrote:
Make sure you're exporting as a "Desktop Cutting Plotter" file, not an "AutoCAD DXF" file.

 -Marius


If you reply to this email, your message will be added to the discussion below:
http://forum.openscad.org/Rendering-DXFs-from-Inkscape-tp11789p11794.html
To unsubscribe from Rendering DXFs from Inkscape, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

kintel
Administrator
Those two screenshots are the same.

I did exactly what you did.
Are you sure you’re just not seeing the object because you drew it far away from the origin? i.e. zoom out a bit and it will appear?

In the latest version, we have a “View All” button.

-Marius
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

GamerDarling
This post has NOT been accepted by the mailing list yet.
....so it was something ridiculously simple, thank you! I tested that on the different files I've created, and that worked on one of the files I made, so now I just need to figure out what I did differently on that file. Thank you! I feel so silly for not trying that on all of the ones that didn't have errors. 

Sidenote, how do I position things closer to the origin? 

On Sun, Mar 1, 2015 at 12:09 PM, kintel [via OpenSCAD] <[hidden email]> wrote:
Those two screenshots are the same.

I did exactly what you did.
Are you sure you’re just not seeing the object because you drew it far away from the origin? i.e. zoom out a bit and it will appear?

In the latest version, we have a “View All” button.

-Marius



If you reply to this email, your message will be added to the discussion below:
http://forum.openscad.org/Rendering-DXFs-from-Inkscape-tp11789p11799.html
To unsubscribe from Rendering DXFs from Inkscape, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

kintel
Administrator
Just move it in Inkscape. I think inkscape places the origin in the bottom left corner of the page.
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

basile
I have been using this same tutorial for importing dxfs into my scad files.
Only on step 6 I am using the "Extensions - Modify Path - Flatten Beziers" with a value of 0.1

Apart from that in order to exactly locate my imported dxfs I use the "dxf_cross" mentioned here: http://en.wikibooks.org/wiki/OpenSCAD_User_Manual/General#Getting_input

You can see how I use it lines 516-519 and lines 900-903
Code is in BasWheel.scad file
DXF files are BasSpoke1.dxf and rc1_10.dxf (I also have the source svg files too)

Files can be found here: https://github.com/basile-laderchi/BasWheel
basile
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

shadowwynd
I use Inkscape and OpenSCAD together frequently.  

my steps:

1 - Draw object in Inkscape
2 - Move object to lower left corner of page, align left/right center marker to left page border, align top/bottom center marker with the bottom page border (it may help to turn off the page shadow in Document Properties)
3 - Select Objects you want to export
4 - Convert to Path: Path --> Object to Path (Ctrl+Shift+C)
5 - Flatten Beziers: Extensions --> Modify Path --> Flatten Beziers   (adjust the value based on granularity you need; I use 0.3 or 0.1 for most things)
6 - Save as Desktop Cutting Plotter (Autocad DXF R14) .DXF file
7 - Make sure the ROBO-Master spline option is unchecked, LWPOLYLINE option is checked.  I keep the base units in mm to be consistent with OpenSCAD.
8 - import the file in OpenSCAD (e.g.  import ("drawing.dxf");     )
Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

GamerDarling
This post has NOT been accepted by the mailing list yet.
Thanks everybody! This has been massively helpful in getting it working and in smoothing out the process so that it'll go better next time. :) 

On Mon, Mar 2, 2015 at 6:52 AM, shadowwynd [via OpenSCAD] <[hidden email]> wrote:
I use Inkscape and OpenSCAD together frequently.  

my steps:

1 - Draw object in Inkscape
2 - Move object to lower left corner of page, align left/right center marker to left page border, align top/bottom center marker with the bottom page border (it may help to turn off the page shadow in Document Properties)
3 - Select Objects you want to export
4 - Convert to Path: Path --> Object to Path (Ctrl+Shift+C)
5 - Flatten Beziers: Extensions --> Modify Path --> Flatten Beziers   (adjust the value based on granularity you need; I use 0.3 or 0.1 for most things)
6 - Save as Desktop Cutting Plotter (Autocad DXF R14) .DXF file
7 - Make sure the ROBO-Master spline option is unchecked, LWPOLYLINE option is checked.  I keep the base units in mm to be consistent with OpenSCAD.
8 - import the file in OpenSCAD (e.g.  import ("drawing.dxf");     )



If you reply to this email, your message will be added to the discussion below:
http://forum.openscad.org/Rendering-DXFs-from-Inkscape-tp11789p11814.html
To unsubscribe from Rendering DXFs from Inkscape, click here.
NAML

Reply | Threaded
Open this post in threaded view
|

Re: Rendering DXFs from Inkscape

miloh
In reply to this post by shadowwynd
re: processing with inkscape

you can 'resize the page to drawing' in Inkscape, which helps with
getting expected output. I inserted an optional step below that
describes how it works in my 0.91pre version that should work for most
all versions:

On Mon, Mar 2, 2015 at 5:52 AM, shadowwynd <[hidden email]> wrote:
> I use Inkscape and OpenSCAD together frequently.
>
> my steps:
>
> 1 - Draw object in Inkscape
> 2 - Move object to lower left corner of page, align left/right center marker
> to left page border, align top/bottom center marker with the bottom page
> border (it may help to turn off the page shadow in Document Properties)

Resize page to drawing:
in Inkscape, from the File menu, select 'document properties', and go
to the orientation section of the document properties dialog, click
the section pointer at 'resize page to content' to expand, and click
resize page to drawing or selection.

> 3 - Select Objects you want to export
> 4 - Convert to Path: Path --> Object to Path (Ctrl+Shift+C)
> 5 - Flatten Beziers: Extensions --> Modify Path --> Flatten Beziers
> (adjust the value based on granularity you need; I use 0.3 or 0.1 for most
> things)
> 6 - Save as Desktop Cutting Plotter (Autocad DXF R14) .DXF file
> 7 - Make sure the ROBO-Master spline option is unchecked, LWPOLYLINE option
> is checked.  I keep the base units in mm to be consistent with OpenSCAD.
> 8 - import the file in OpenSCAD (e.g.  import ("drawing.dxf");     )
>
>
>
>
> --
> View this message in context: http://forum.openscad.org/Rendering-DXFs-from-Inkscape-tp11789p11814.html
> Sent from the OpenSCAD mailing list archive at Nabble.com.
>
> _______________________________________________
> 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