PDA

View Full Version : Truly stupid CorelDraw question



Lee DeRaud
05-18-2005, 3:27 PM
Not having any luck getting to the CorelDraw newsgroups, so I'll try here...

The simplest statement of the problem is as follows:
Three lines are drawn on a blank page, but not through a common intersection. This results in a triangle bounded by those lines. How do I make a shape that corresponds to that triangle?

In the more general case, how do I create shapes that correspond to the regions bounded by an arbitrary number of open curves?

I've tried every obvious combination of selecting the lines and using the 'shaping' commands (Trim, Intersect, etc)...no joy. I suspect that exporting the drawing as a bit map, using flood fill to color the regions, and then bringing the result back in through CorelTrace will work, but that seems ridiculously kludgy.

Any ideas?

Jerry Allen
05-18-2005, 6:04 PM
Are the lines intersecting?

Jerry Allen
05-18-2005, 6:13 PM
No matter.
First of all Trim, intersect, etc., only apply to closed objects.
I will assume you are using V12 for now.
Using the pick tool, get the corners fairly close together. If you have Dynamic Guides, turn it on from the view menu. This will allow you to connect the nodes easier. If not use Snap to Objects.
Select all three lines and select Combine from the right click menu or the Arrange menu.
Then use the node tool to make a selection box around the pairs of nodes at the vertices and right click and select Join. When you have done all three, you should have a closed triangle.

A quicker way is to use the Polygon tool is you are using V12, or make a rectangle and use the Node edit tool to delete one of the nodes. Then using the Pick tool rotate and stretch as necessary.

Robert Stremcha
05-18-2005, 7:23 PM
I would use the Bezier tool and simply click at each corner around the shape, resulting in lines that are connected by nodes. Then if necessary, edit the nodes, change lines to curves etc. That will work with any shape, no matter how complex. :cool:

Lee DeRaud
05-18-2005, 8:22 PM
No matter.
First of all Trim, intersect, etc., only apply to closed objects.
I will assume you are using V12 for now.
Using the pick tool, get the corners fairly close together. If you have Dynamic Guides, turn it on from the view menu. This will allow you to connect the nodes easier. If not use Snap to Objects.
Select all three lines and select Combine from the right click menu or the Arrange menu.
Then use the node tool to make a selection box around the pairs of nodes at the vertices and right click and select Join. When you have done all three, you should have a closed triangle.

A quicker way is to use the Polygon tool is you are using V12, or make a rectangle and use the Node edit tool to delete one of the nodes. Then using the Pick tool rotate and stretch as necessary.

Ok, I see my explanation was less than clear. Yes, the lines intersect. Assume for the moment that they run all the way across the page. The shape I want to create is the bounded region with vertices at the three pairwise intersections.

But I definitely don't want to have a solution that depends on the sides of the region being straight: obviously, for the straight-line case, I could just use 'snap-to-intersection' and play "connect-the-dots".

Consider a checkerboard. CorelDraw seems to assume that you will build it up out of 32 black-filled rectangles and 32 red-filled rectangles. What you can't seem to do is draw a frame, draw seven vertical lines and seven horizontal lines, and then set the fill color of the resulting squares, which (to me at least) is more intuitive.

What's driving this is doing laser-cut inlay, where drawing the design is almost trivial if you think in terms of the lines rather than the enclosed regions. Problem is, I want to be able to contour those enclosed regions to eliminate the "kerf" when I cut them.

Rodne Gold
05-19-2005, 1:10 AM
Unless you have complex fills or hatches , this would be very difficult (the chequerboard) , It can be done in programs like Autocad. In Corel , You have to create a closed entity to do what you want. Corel will allow filling of open curves , but the triangle thing you are talking about is 3 lines , not a single curve so it wont fill.
Autocad will actually be a far better option for the triangle thing as you could offset the lines inwards byyour compensation distance and trim the 3 offset lines to make an inner triangle. Import into Corel and hey presto. Corel will also offset (called contour) these lines but it offsets all around the line to create a thin rectangle which is much more difficult to manipulate to get the inner triangle.
Offsets are complex entities and not everything can be offset. Apart from which , corel does horrible things with contours and nodes , sometimes an entity contoured in or out will now have a LOT more nodes than the original.
If you do do a lot of inlays , then a package like engravelab or profilelab is worthy of consideration as it allows complex toolpaths with inlay compensation , male female type compensation etc and some other nice things in respect of machine paths (that can be applied to lasers) without actually explicitly doing it in the drawing. However you would STILL have to have that inner triangle to do so , it wont work with the 3 intersecting lines.

Lee DeRaud
05-19-2005, 9:13 AM
Unless you have complex fills or hatches , this would be very difficult (the chequerboard) , It can be done in programs like Autocad. In Corel , You have to create a closed entity to do what you want. Corel will allow filling of open curves , but the triangle thing you are talking about is 3 lines , not a single curve so it wont fill.
Autocad will actually be a far better option for the triangle thing as you could offset the lines inwards byyour compensation distance and trim the 3 offset lines to make an inner triangle. Import into Corel and hey presto. Corel will also offset (called contour) these lines but it offsets all around the line to create a thin rectangle which is much more difficult to manipulate to get the inner triangle.
Offsets are complex entities and not everything can be offset. Apart from which , corel does horrible things with contours and nodes , sometimes an entity contoured in or out will now have a LOT more nodes than the original.
If you do do a lot of inlays , then a package like engravelab or profilelab is worthy of consideration as it allows complex toolpaths with inlay compensation , male female type compensation etc and some other nice things in respect of machine paths (that can be applied to lasers) without actually explicitly doing it in the drawing. However you would STILL have to have that inner triangle to do so , it wont work with the 3 intersecting lines.

Ok. You're confirming a suspicion I've had ever since I started with Corel a couple months ago: I've still got a "CAD mindset" and some of the ways I'm used to doing things just Do Not Work. So it goes.

Also, I tend to say "inlay" when I mean to say "marquetry". The real answer may be to do more work at the bitmap level before switching to Corel...although PhotoPaint has Issues all its own.

Thanks for the assist.

Lee DeRaud
05-19-2005, 10:27 AM
Just to prove that I'm persistent (and not completely crazy), here's what I tried next. (The frustrating this is, it *almost* works.)

1. Draw a tic-tac-toe pattern, then draw a rectangle "inside" the outer ends of those lines. Result is a 3x3 grid with some "tails" hanging out. (Page 1 of attached drawing)
2. Select all, then apply 'front minus back' shaping. Result is a single curve. (Page 2)
3. Select the curve and apply "break curve apart". I'd expect to see 9 objects as a result...nope, it says *10*. (Page 3)
4. Apply fill/border to each object and "explode" it: there are eight of the nine expected rectangles and some truly odd stuff. (Page 4)

I've tried it a couple of times with different number of lines and intersection topology, and get similar results: some of the "cells" are just what I expect (and want), and a couple are just plain strange. Any clue what's going on here?

Aaron Koehl
05-19-2005, 11:04 AM
Lee,

There are a number of methods for calculating the bounded region in CorelDRAW. The best method depends on the geometry and objects in question. I am currently using Corel 11 here, but you can do the same in 12, and should be able to do it in 10.

Creating bounded regions with closed objects is pie. The trick is, how to create them with unclosed Bezier curves (or straight lines, for that matter).

Here is Method #1 (Contouring)

1. Draw your curves or lines:
http://www.sawmillcreek.org/images/aaron/bounding1_1.gif

2. Select the objects and Weld (or combine):
http://www.sawmillcreek.org/images/aaron/bounding1_2.gif

3. Apply a small contour (say, .001 in). This creates closed objects. (aha!)

http://www.sawmillcreek.org/images/aaron/bounding1_3.gif

4. Break the contour apart. (and delete your old object, if you please).

http://www.sawmillcreek.org/images/aaron/bounding1_4.gif

5. Break the curve apart. (and delete the bounding curves, if you please).

http://www.sawmillcreek.org/images/aaron/bounding1_5.gif

And.. you've a bounded region:

http://www.sawmillcreek.org/images/aaron/bounding1_6.gif

Gary Shoemake
05-19-2005, 12:30 PM
Aaron
You made that really clear, your explaination helped me understand what was being discussed

Thanks

Gary

Aaron Koehl
05-19-2005, 1:18 PM
Method 2 is easier. It's the same as Method #1 but actually lets Corel do the work for you.

Here is Method #2 (Outlines)

1. Create your curves.
http://www.sawmillcreek.org/images/aaron/bounding2_1.gif

2. Weld (combine) your curves into an object.
http://www.sawmillcreek.org/images/aaron/bounding2_2.gif

3. Arrange > Convert Outline to Object (ctrl+shift+q)
http://www.sawmillcreek.org/images/aaron/bounding2_3.gif

4. Break curve apart, delete the lines, and you're done.
http://www.sawmillcreek.org/images/aaron/bounding2_4.gif

And you're done..
http://www.sawmillcreek.org/images/aaron/bounding2_5.gif

Lee DeRaud
05-19-2005, 1:47 PM
Lee,

There are a number of methods for calculating the bounded region in CorelDRAW. The best method depends on the geometry and objects in question. I am currently using Corel 11 here, but you can do the same in 12, and should be able to do it in 10.

Creating bounded regions with closed objects is pie. The trick is, how to create them with unclosed Bezier curves (or straight lines, for that matter).

Here is Method #1 (Contouring)

1. Draw your curves or lines:

2. Select the objects and Weld (or combine):

3. Apply a small contour (say, .001 in). This creates closed objects. (aha!)

4. Break the contour apart. (and delete your old object, if you please).

5. Break the curve apart. (and delete the bounding curves, if you please).



Perfect. Turns out it works for an arbitrary number of bounding curves and bounded regions if I just close off the desired region with four lines (*not* a rectangle). There are a few issues if there are "tails" (bounding curves that terminate inside the outer boundary), but it's workable.

Thanks!!

Lee DeRaud
05-19-2005, 1:55 PM
Method 2 is easier. It's the same as Method #1 but actually lets Corel do the work for you.

Here is Method #2 (Outlines)

1. Create your curves.
2. Weld (combine) your curves into an object.
3. Arrange > Convert Outline to Object (ctrl+shift+q)
4. Break curve apart, delete the lines, and you're done.
And you're done..


Way cool: that one even works if there are actual closed objects embedded in the region.

Thanks^2!

I'm beginning to think that the Corel corporate motto is: "Just because it's easy doesn't mean it's obvious." :p

Aaron Koehl
05-19-2005, 2:29 PM
Aaron
You made that really clear, your explaination helped me understand what was being discussed

Thanks

Gary

You're welcome.. :D