LDraw.org Discussion Forums

Full Version: BFCing
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Does anyone of you have an executable of WINDZ available to give me?
It seems to not be downloadable anywhere anymore.
I've been BFCing parts in the past some time, always using the "manual method", i.e.,
looking at the part in LDView, identifying the wrongly oriented faces, coloring them in MLCad,
then changing their winding in LDDP, or inserting INVERTNEXT's.
When I look at parts in red/green BFC checking mode in LDView, I always thought
that the BFCing process - to a certain extent - should be easily automatable;
I think that's what WINDZ also does:
just render the part from various perspectives, and flip all faces that appear "red" during that.
Of course, if a surface gets flipped twice this way, it cannot automatically be oriented correctly,
and manual post-correction is needed. However, for a majority of parts, the described
method should trivially work like a breeze.
Does anyone of you know of software which does that?
I want to speedup my BFCing processing...
Having such a software would allow us to instantly BFC big amounts of our library,
and reduce the remaining manual work to the parts which really require attention.
My best preference would be a tool like edger, command line based,
and simply taking an input file, outputting a result file where all faces are oriented correctly,
and the file otherwise unchanged. Undecidable surfaces should be colored in a user-selected color,
so they can be taken care of manually.
Check your email.
Windz is also included in latest LETGUI package.
It works fairly well on closed volume, but has trouble with open stuff (eg. subparts). Another quirck is that it inserts an invertnext in front of flat primitives instead of flipping them.
Thanks Orion, will try it.
Philo, the 2 problems you mentioned appear easily fixable to me.
Flipping primitives instead of inserting INVERTNEXT should be trivial.
And regarding the open surfaces, this can be cured as well: the tool should simply detect
if a surface is visible from 2 sides, and if yes, colorize it specially and keeps fingers of that,
since it cannot know in which orientation it is desired.
Sad that the tools seems to be no longer actively developed, applying these 2 fixes seems
nearly trivial to me.
I will use this message to collect the bugs I further discover in the tool.

Bug #1:
On Win7 64bit, crashes immediately when invoked with empty command line:
Code:
Problem Event Name:    APPCRASH
  Application Name:    windz.exe
  Application Version:    0.0.0.0
  Application Timestamp:    3d81e30a
  Fault Module Name:    windz.exe
  Fault Module Version:    0.0.0.0
  Fault Module Timestamp:    3d81e30a
  Exception Code:    c0000005
  Exception Offset:    0000162d
  OS Version:    6.1.7601.2.1.0.256.1
  Locale ID:    1031
  Additional Information 1:    aefb
  Additional Information 2:    aefbda89c057c86b72e54293b84f7f43
  Additional Information 3:    a82d
  Additional Information 4:    a82d76f570636604c9c9bb7b313890f2
When invoked with file as parameter, does not crash.
the result is unsatisfying.

the strange thing here is that the tool works correctly on one side of the part,
but on its other side, which is completely symmetric, does not work correctly.
This lets me suspect that there is a +/-1 multiplication error somewhere in its internal matrix formulae,
which lets it work correctly in some quadrant of the coordinate system, but not in another.
The problem with 3229b.dat is that it contains two concave quads, and it seems this bothers Windz... Correct them first, and windz will do it's thing fine!
I have a few questions concerning BFC.
First of all: What does BFC stand for?
Does the orientation concern the part only or the pattern also? Since I'm just doing patterns I don't know if I have to do anything. I looked at the part in LDView in BFC Mode but I don't have a clue what I'm looking at. Could someone enlighten me, please?
BFC means Back Face Culling. See the related LDraw specification, and Wikipedia defintion.
The best way to have a feel for it is to look at a part LDView in BFC Mode (use BFC red back face / green front face option). If you see red, it means you see the facet from the wrong side. Have a look to a subpart (they are generally not closed so you may look "from inside")...
For your pattern, LPC does the work for you... you just have to change the "0 BFC NOCERTIFY" to "0 BFC CERTIFY CCW"
Philippe \Philo\" Hurbain Wrote:For your pattern, LPC does the work for you... you just have to change the "0 BFC NOCERTIFY" to "0 BFC CERTIFY CCW"

Thank you, Philo. Do I just have to change it in File -> Metadata, or somewhere else, too?
Pages: 1 2 3