Infinite Radius after Squish

unhandled

(Direyes 11) #1

Hello everyone. Currently I am working in a project to obtain the exact perimeter of different geometries before bending process. To obtain that, I am applying the squish command but in order to cut the pieces DXF files must be readable for the machine. Before the squish the radius of the surface had the predetermined value. After the squish the radius are infinite so the cutting machine does not read the file.

There is a way to modify the command in order to have the files correct for the machine. Thanks to everyone.


(Pascal Golay) #2

Hello - are you referring to the radius of an edge curve? Squish makes polyline edges (Infinite radius of course, on the segments) , so you may have some work to do - can you post your surface or send to tech@mcneel.com?

-Pascal


(Direyes 11) #3

Patrón_radio.3dm (1.2 MB)

Yes, I am referring to the edge radius. In the file is one of the surfaces before and after the squish.


(Pascal Golay) #4

Hello - is the part you are interested in just the edge curve and not the mesh output? For something this simple, reverse engineering the arcs (Arc > Start,End,PointOnArc) on the corners and adding lines is probably an easy enough solution. If you have a lot of these, ore more complex curves, it might get tedious.

-Pascal


(Direyes 11) #5

Hello. Yes, there are more complex surfaces and the idea is to generate the DXF files automatically, so I am developing in grasshopper the programming to obtain the files. However the cutting machine does not read correctly the files for this reason. There is a way to correct that using grasshopper or is it necessary to make it manual?


(Pascal Golay) #6

Hello - if you do not need true arcs and straights, and an interpolated curve will do, I can offer a script to interpolate the border polylines - if you think that will help, I can dig up the script and we can try it.

-Pascal


(Direyes 11) #7

Hello. I think it would be helpful. Let´s give it a try. Thank you


(Pascal Golay) #8

Hello - here is a python to try - I’m not sure how it will fit into your workflow - I think it may be tricky to automate this reliably, but this seems to do an ‘ok’ job on the file you sent. Set the StraightnessRatio to 2 for this curve - one problem is that results are sensitive to this setting and I do not know how it will work from input to input.

InterpPolyline_05_30_18.py (7.3 KB)

Use RunPythonScript to test - I am sure there is plenty to adjust and fix here to make it at all robust…

-Pascal


(Direyes 11) #9

Hello. I got a question, how the script works? I ran it but did not see any results, the object I selected not show any changes.


(Pascal Golay) #10

I’ll post my results - hold on a second…

Patrón_radioOutline_PG.3dm (1.1 MB)

StraightnessRatio=2
BreakAngle=30

-Pascal


(Direyes 11) #11

Hello. Thank you so much for the help. One last question, what is the meaning of BreakAngle? Just to know wich value goes with other surfaces.


(Pascal Golay) #12

BreakAngle is the angle at which the polyline is considered by the script to have a hard corner between two segments and not be an approximation of a curve at that point.

-Pascal


(Direyes 11) #13

Hello. I am presenting some troubles when the geometry changes. Attached is the surface I am using currently. When I increase the StraightnessRatio, the script does not create arcs very well. So when the dxf file is created the radius appear again as infinite.

Thank you so much for the help.

Script_test.3dm (549.3 KB)


(Pascal Golay) #14

The Convert command on this output may help - set Output=Arcs, AngleTolernce=0

-Pascal