Subject:
|
Re: BFCFixer
|
Newsgroups:
|
lugnet.cad.dev
|
Date:
|
Thu, 3 Feb 2005 12:26:46 GMT
|
Viewed:
|
2494 times
|
| |
| |
In lugnet.cad.dev, Chris Dee wrote:
> I may be being dense here, but I dont understand how this can be done
> programatically.
The way it's been done before is to draw rays from the origin outward. The
first polygon a ray crosses is facing inward, and the last polygon a ray crosses
would be facing outward. The ones in between *should* alternate facing in and
out. Do this for a bunch of rays, compile statistics, and many polygons will
end up with obvious direction they should be facing. Wrap those polygons, wrap
all polygons adjacent to those polygons, repeat until you run out of polygons.
Another way to do it would be to modify an ldraw renderer to also render a 'hit
map'. That is, for each pixel in the scene, record which source-file command
line creates that pixel. Any polygon-line included in the final hit map would
be facing toward the viewer. Wrap those polygons, wrap all polygons adjacent to
those polygons, repeat until you run out of polygons.
Steve
|
|
Message is in Reply To:
| | Re: BFCFixer
|
| (...) I may be being dense here, but I dont understand how this can be done programatically. The point of BFC is to allow renderers to understand if a particular polygon is facing the camera or facing away from it. If all polygons are wound (...) (20 years ago, 3-Feb-05, to lugnet.cad.dev)
|
22 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|