XPlane2Blender icon indicating copy to clipboard operation
XPlane2Blender copied to clipboard

OBJ conditionals is not implemented properly, or hardly at all

Open tngreene opened this issue 7 years ago • 2 comments

In the X-Plane OBJ spec, it lists one feature as conditionals for turning off objects based on features of X-Plane turned on:

Conditionalization

[X-Plane 1000:] X-Plane 10 supports the conditionalization of OBJ files.  Conditionalization is a process whereby the contents of a file are skipped or used depending on rendering settings.  Typical uses of conditionalization are to change the appearance of an object when shadows are enabled, or when HDR is on.

Conditionals for OBJs occur in the form of these commands:

IF <var>
IF NOT <var>
ELSE
ELSE IF <var>
ELSE IF NOT <var>
ENDIF

In the XPlane2Blender the word "ELSE" literally never appears. Only IF, IF NOT, and ENDIF are written. Is the spec wrong, deprecated, or is this not feature complete?

It is only tested in the unit tester as a sub test in "various.test.py", testing only IF, IF NOT, and ENDIF

tngreene avatar Aug 03 '17 14:08 tngreene

In addition, they do not wrap around the ANIM_ directives which seems kinda wasteful. Why have X-Plane load animations if the object will just get turned off?

tngreene avatar Aug 03 '17 14:08 tngreene

@bsupnik any notes for this to close it off either way?

tngreene avatar Sep 04 '17 14:09 tngreene