Subject:
|
Re: non-lego rendering using various LDraw tools
|
Newsgroups:
|
lugnet.cad.dat.ideas
|
Date:
|
Thu, 23 Sep 2004 19:41:49 GMT
|
Viewed:
|
4610 times
|
| |
| |
In lugnet.cad.dat.ideas, Don Heyse wrote:
|
In lugnet.cad.dat.ideas, Steve Bliss wrote:
|
In lugnet.cad.dat.ideas, Don Heyse wrote:
Yep, thanks for doing that. Then I turned around and installed
Cygwin, so now I probably have gcc available -- I think.
|
Id imagine so. I dont actually use Cygwin. I use the
mingw version of gcc on Windows because
I dont want to worry about the Cygwin unix compatibility DLL.
|
Ha. Once youve got vertices and edges, writing the Triangle format is
pretty straightforward. The only tricky bit (and one I did not solve) is
telling Triangle the location of holes. If you have open spaces in your
image, you have to tell Triangle, or it will happily pave over them.
|
Its not too hard to detect holes while youre vectorizing edges, just
look at the pixel color above the highest point on each closed polyline.
You can encode this by writing outside edges clockwise and inside edges
counter-clockwise. I dont remember if autotrace can do this. Ill
have to check.
|
Err, reverse course. I peeked at the autotrace source and it says
in pxl-outline.c Outside outlines are traced counterclockwise. So
if you want to make things easier for me, do it that way. ;^)
|
|
Ill happily share what Ive done, especially if I ever finish it. But
(working with Autotrace) you were probably were ahead of what I
accomplished. But Id be interested in looking at your code. :)
|
The autotrace source code for LDR output from May is
here. I put the executable
here, but I dont remember how
to run it.
Theres a batch file I used to test it in the source zip
file, but that might
not have all the right options for a real world
example.
Don
|
|
|
Message has 1 Reply: | | Re: non-lego rendering using various LDraw tools
|
| (...) OK. My edges already were counterclockwise. :) Umm, for inside outlines (inlines?) to be clockwise, that's 'clockwise' from a global view, right? If so, then my inlines are already clockwise. But I don't know which ones are inlines, and which (...) (20 years ago, 23-Sep-04, to lugnet.cad.dat.ideas, FTX)
|
Message is in Reply To:
| | Re: non-lego rendering using various LDraw tools
|
| (...) I'd imagine so. I don't actually use Cygwin. I use the (URL) mingw> version of gcc on Windows because I don't want to worry about the Cygwin unix compatibility DLL. (...) It's not too hard to detect holes while you're vectorizing edges, just (...) (20 years ago, 23-Sep-04, to lugnet.cad.dat.ideas, FTX)
|
8 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|