Increasing/decreasing outline size by a specific offset

Use this forum to ask questions about how to do things in QCAD version 3

Moderator: andrew

Increasing/decreasing outline size by a specific offset

Postby 0xdeadbeef » Sun Aug 10, 2014 2:38 pm

Bare with me if this is a stupid question (and it probably is), but what is the most elegant way to shrink/extend an object so its outline is by a certain amount larger/smaller than the current one?

I can achieve this either by scaling, but calculating the factor can be tricky and I'm concerned that the resulting coordinates are not precise (i.e. 2.9998 instead of three). I also helped myself by constructing the new outline with parallel lines etc., which results in an exact outline but is a lot of work.

As a background: I'm creating outlines for laser cutting (not cutting myself though but sending them to Formulor where they accept only SVG). Since I now that the kerf will be e.g. 0.2mm for a certain thickness, I want to compensate this by increasing/decreasing the ideal outline by this amount.
0xdeadbeef
Junior Member
 
Posts: 16
Joined: Sun Aug 10, 2014 11:58 am

Re: Increasing/decreasing outline size by a specific offset

Postby Husky » Sun Aug 10, 2014 6:11 pm

Hi Oxdeadbeef - welcome in the forum!

Just to be sure that we are talking about the same thing: You are looking do create something like this "red dash" line around the white given shape for a CnC job?

Husky-2014.08.10-01.png
Husky-2014.08.10-01.png (15.69 KiB) Viewed 395 times


If not - could you please attach an example dxf. Thanks.
Work smart, not hard: QCad Pro
User avatar
Husky
Moderator
 
Posts: 667
Joined: Wed May 11, 2011 9:25 am
Location: USA

Re: Increasing/decreasing outline size by a specific offset

Postby 0xdeadbeef » Mon Aug 11, 2014 6:31 pm

Yep. Just not on both sides.
Simplest example: I want to cut a circle from e.g. a transparent material (layer 1) and insert it in a hole in an opaque material (layer 2). Since I know that the CO2 laser will create an kerf of ~0.2mm, I want to reduce either the hole size or increase the circle size by by 0.2mm to compensate the kerf.
Now for a circle this is easy. For a complex object though, I didn't find an elegant way to do this yet.
0xdeadbeef
Junior Member
 
Posts: 16
Joined: Sun Aug 10, 2014 11:58 am

Re: Increasing/decreasing outline size by a specific offset

Postby Husky » Mon Aug 11, 2014 8:30 pm

0xdeadbeef wrote:For a complex object though, I didn't find an elegant way to do this yet.


Ok - understood. For simple entities like a line or a circle the "Line tool" / "Parallel with distance" would do the job.

For more complex objects I would recommend to get familiar with the use of Polylines. You can create a shape in first place as a Polyline or you can create a Polyline based on a Selection. The nice thing about a Polyline shape is - you can use the Polyline Offset Tool to handle easily the needed offset to compensate the kerf of a CO2 Laser etc. etc. etc.

Check this out (yes I know - it's ugly!):
Husky-2014.08.11-01.png
Husky-2014.08.11-01.png (50.24 KiB) Viewed 381 times


Try this for yourself:
Load this drawing and play around with the Polyline / Offset tool (Menu -> Draw -> Polyline -> Offset). An additional Option-bar will pop up and you can put in the correct value for the kerf.
test.dxf
(87.89 KiB) Downloaded 11 times

Will this suits your needs?
Work smart, not hard: QCad Pro
User avatar
Husky
Moderator
 
Posts: 667
Joined: Wed May 11, 2011 9:25 am
Location: USA

Re: Increasing/decreasing outline size by a specific offset

Postby 0xdeadbeef » Mon Aug 11, 2014 10:04 pm

Ah, that's exactly what I searched for - but the "polyline from segment" thing was hidden to deep and located in a menu (draw) where I didn't expect it.
But ok, that seems to work just great. Thanks!
[Edit]
Sorry for bugging, but while converting shapes into polylines something weird happened in one case. See appended screenshot. The outline and the rectangular section where merged into one polyline. I don't quite understand how this could have happened as obviously this can't be one polygon and I understood a polyline can't contain intersections!?
Attachments
polyline.png
polyline.png (3.45 KiB) Viewed 375 times
0xdeadbeef
Junior Member
 
Posts: 16
Joined: Sun Aug 10, 2014 11:58 am


Return to QCAD 3 'How Do I' Questions

Who is online

Users browsing this forum: No registered users and 1 guest