
org.j3d.loaders.discreet.package.html Maven / Gradle / Ivy
Classes for parsing Discreet's 3DS Max .3ds file format.
A parser that handles the raw structural information of the file and returns
objects that correspond to the structure. No attempt is made to change the
raw values as reported by the file except for colours. All colour values are
normalised to a 3-component float value. 3DS likes to dump invalid colour
values with ranges outside the normal [0,1] range, but we leave anything like
that as is.
Implementation notes
When walking through the various classes, you will see that they roughly match
the chunk pattern of the 3DS file. Some shortcuts have been taken here and there
where the chunks were starting to get way too small for any usable benefit.
Colour values are all normalised into the normal floating-point format. If the
original values were presented as byte for (24 bit colour) they are normalised to
the normal [0,1] range for floats. Values that were sourced as floats keep the
exact value. Since 3DS (and MAX) are both known to export colours outside of this
range, expect that some values will be encountered this way and prepare to range
cap as appropriate.
Percentage values are always presented as a fractional value between 0 and 1
regardless of whether the original value was written as an integer or floating
point value.
If you need something that reads to a form that is renderable by a rendering
engine, you will need to visit the various renderer-specific packages under
org.j3d.renderer.renderer_name.loaders
.
External References