MoI discussion forum
MoI discussion forum

Full Version: exporting 2d

Show messages:  1  2-21  22-41  42-50

From: Michael Gibson
12 Sep 2007   [#2] In reply to [#1]
Hi Paul, probably your best bet at the moment would be to use Rhino (http://rhino3d.com) to convert your curves to DXF format.

I do plan on adding DWG and DXF support to version 2.

But I think it may be possible for me to cook up a basic 3DM to DXF conversion program before then that might work. It would be pretty basic, probably just break curves into polylines and not try to convert circles as circle entities, etc... Do you think that would do the job?

If so, maybe you can send me a few example DXF files zipped up to me at moi@moi3d.com. I'll take a look at them and see if it might be possible for me to do a kind of basic converter program.

- Michael
From: paul (PBELGRADO)
12 Sep 2007   [#3] In reply to [#2]
Michael ,

Thanks for the reply I just sent the files to you .


Greets ,

Paul
From: tyglik
12 Sep 2007   [#4] In reply to [#1]
Hi Paul,

>>"sheetcam" is a 2 and 1/2D cam program and it is very fast and easy to rout holes pockets etc.
>>The only problem is that it needs dxf files .

If SheetCAM can generate a path from "21/2D" or 3D DXF file then you could try translating STL file to DXF one by ADMesh (http://www.varlog.com/products/admesh/).

So after you download and unzip this file, the workaround would be:
- draw 2d curves in MoI
- extrude it slightly (e.g. 10 units)
- export surfaces as STL (only upper/lower edge will be important when adjusting mesh parametres in meshing dialog window)
- put the STL file along with "admesh.exe" and "stl2dxf.js" in the same directory
- run stl2dxf.js (double click on it)
- you should get a DXF files for all STL files which will be found in given directory

Now, you can try importing DXF file into SheetCAM...

Petr

Attachments:
stl2dxf.zip


From: paul (PBELGRADO)
13 Sep 2007   [#5] In reply to [#4]
Petr ,

Thanks for the reply .
I will try your suggestions .
I already did export in stl by giving the drawing a certain thickness but I wasn't able to take the thickness off in the programs I tried .(blender, turbocad etc )
Sheetcam reads only 2d files .(I use dxf ) .
Michael is trying to write some basic 3dm to dxf module so we'll see what that is going to be .( what a great service !! )
I can do my main contour with my 3d program ( cut3d from vectric ) but some operetion function better in 2 1/2 d.
I'll post some pictures soon of the cam and the physical routing .
For the manufacturing of these guitar models I will have to do different operations on the same object so I'll machine 2 1/2 d and 3d in separate steps .I will not machine the whole model at once . I just have a home constructed cnc router so I don't have the option of doing complex toolchanges and so .
Well I'm going to try admesh now I'll let you know what happens .
Here's already an attachement of a visual contour path with cut3d from a model extruded from a basic 2d drawing in Moi.

Thanks ,

Paul

Attachments:
cutout.jpg


From: eddi
13 Sep 2007   [#6] In reply to [#5]
G-Cod no alternative for your cnc-router??
www.cncportal.com/downloadfree.htm
work with opennurbs (3dm)
From: paul (PBELGRADO)
13 Sep 2007   [#7] In reply to [#6]
Thanks for the link Eddi ,

I downloaded the program an it seems quite nice .( and free )
My 3d cam program ( cut3d from vectric ) can import 3ds and stl so I can go straight from moi into that .It has a bit more features than freemill.
It's usefull for most routings but it routs in rasters like the "freemill" program .
For fast pocket and accurate routings in the main body shape it's easier to use 2 1/2 d cam ( with dxf )

Petr ,

I tried the ADmesh , It gives me a dxf but not really readable .
When I use for instance Blender . I can export from moi to blender in STL ( extruded ) .
I can take of the height visually but when I save to dxf in Blender it gives me a DXF file with the original height again.
Maybe I haven't studied Blender enough .
So I'll keep on trying .

Thanks ,

Paul
From: Michael Gibson
13 Sep 2007   [#8] In reply to [#7]
Hi Paul, I cooked up a converter for you, you can download it from here:
http://moi3d.com/download/3dmCurves2DXF.zip

Unzip this to some folder, then run the 3dmCurves2DXF.exe program.

It will ask you for the name of an input .3dm file, and then the name of an output .dxf file.

It will read through the input .3dm file and convert any curve objects it finds to Spline entities in the DXF file.

Please let me know if this works to transfer your curve data over.

- Michael
From: paul (PBELGRADO)
13 Sep 2007   [#9] In reply to [#8]
Hi Michael ,

Superb !!!!! and a big thanks for the work .
I'll be running some tests right away and I'll let you know .

Greetings ,

Paul
From: paul (PBELGRADO)
13 Sep 2007   [#10] In reply to [#9]
Michael ,

First of all thank you very very much for the mini 3dm to dxf convertor .
It works quite well and it should be just right for my purposes .
I opened it in Turbocad and some other programs I have ( freeware , alibré x press, solidedge 2d ).
The splines that replace the curves are wel in their place .
This mini 3dm to dxf convertor will do the job for me I hope it will be usefull to somebody else also .

I'll keep the forum informed about my guitar building process with Moi .

Paul
From: Frenchy Pilou (PILOU)
13 Sep 2007   [#11]
Works like a charm ! Even the curves 3D (is that normal ?
Bravo!

Attachments:
dxf.jpg


From: Michael Gibson
13 Sep 2007   [#12] In reply to [#10]
Hi Paul, that's great, I'm glad that it will help!

I'm looking forward to seeing some guitar stuff, it would be very interesting if you could take some photos of different stages in the process and post them.


@Pilou - seems like this converter may help in more situations than I had thought!

I'm still planning on doing a much more comprehensive DWG and DXF export for version 2, but this seems to be a good step for transferring curve data to apps that don't support IGES.


> Even the curves 3D (is that normal ?

Yup, it will convert any kind of curve, either flat or 3D.

- Michael
From: paul (PBELGRADO)
13 Sep 2007   [#13] In reply to [#12]
Michael ,

I tried a 3d file and it partially worked .
I'll do some more tests on it in the next days and let you know .


Paul
From: Frenchy Pilou (PILOU)
13 Sep 2007   [#14]
< seems like this converter may help in more situations than I had thought!
yes but after for use it, it's not so evident in the case of curves 3D :)
Yet by the simple aspect thats great, but for use it as entity it's another story :)
because they don't define a planar surface :)
From: Michael Gibson
13 Sep 2007   [#15] In reply to [#13]
Hi Paul, just to make sure we are talking about the same thing - by 3D I meant curve objects that might swoop around with different z values, instead of just being flattened on the xy plane.

Here's one example:




I didn't mean models with surfaces or solids like a sphere or solid box.

If you do run into any problems, please send me a .3dm file with the problem curve in it.

- Michael

Attachments:
helixcrv.jpg


From: paul (PBELGRADO)
13 Sep 2007   [#16] In reply to [#15]
Michael ,

You're right I converted a file with surfaces and some curves . that's why I tought I was missing some lines and curves because they were actually surfaces, and the lines that were still there were the start lines and curves I made before making surfaces with them .sorry about that !!
I'll try some thing in the next days .

Paul
From: Michael Gibson
13 Sep 2007   [#17] In reply to [#14]
This script macro might be useful for some data transfer stuff - this will duplicate every edge of every surface or solid in the scene as a regular independent curve object. Those curve objects can then be processed into DXF using that utility.

You can do this manually by selecting all the edges and doing copy/paste, this just makes it easier to process everything with one keystroke if you've got multiple objects.

code:
script:var breps = moi.geometryDatabase.getObjects().getBReps(); for ( var iBrep = 0; iBrep < breps.length; ++iBrep ) { var brep = breps.item(iBrep); var edges = brep.getEdges(); for ( var iEdge = 0; iEdge < edges.length; ++iEdge ) { var newedge = edges.item(iEdge).clone(); moi.geometryDatabase.addObject( newedge ); } }


To use it, go to Options / Shortcut keys and set up a new one, paste this in as the Command part.

- Michael
From: Frenchy Pilou (PILOU)
13 Sep 2007   [#18] In reply to [#17]
That's works again here from a cube solid :)
each cubes' Edges are divided in small edges

Attachments:
dxf2.jpg
dxf3.jpg


From: Frenchy Pilou (PILOU)
13 Sep 2007   [#19]
But when you select all a face you can create a real face 3D:) (in google Skechup)
(cubes' edges are always divided)

Attachments:
dxf4.jpg


From: paul (PBELGRADO)
13 Sep 2007   [#20]
Hello ,

I just tried the macro script and it all works well . Now I can see all the edge curves of the surfaces when I use the convertor to DXF.

Many thanks ,

Paul
From: Frenchy Pilou (PILOU)
13 Sep 2007   [#21]
In fact i have found a plugin for Sketchup who repair the "lines broken colinear" so that solve my problem for the straight lines on the 3dSpace :)
If someone is interested that is that http://www.crai.archi.fr/RubyLibraryDepot/Ruby/EM/repair_broken_lines.rb

For a 3D curve no linear seems that is more difficult to use it for build a surface :)
But maybe exist a new ruby script who knows? :)

Show messages:  1  2-21  22-41  42-50