LUXINIA F3D Exporter
====================

Based on Motion Model & Animation exporter kindly provided
by Diogo 'fozi' Teixeira with GPL restriction lifted
http://diogo.codingcorner.net/

Installation
=============

copy appropriate dlu in your 3dsmax/plugins directory
You will find the tool in the "Utilities"
The name of the file hints to the max version it is meant
for.

If the plugin (not 64-Bit) fails to initialize copy msvcr71.dll 
from luxinia directory to your 3dsmax directory. 
BUT NEVER OVERWIRTE stuff!! If the file already existed inform us.
on problems:
info 'at' luxinia.de

Useage Notes:
=============

Checkboxes/GUI
--------------
For Animation and Model
# exports only selected:	
	As described, ignores any non selected geometry
# orphans at root:
	When a child node's parent is not exported, it becomes
	an orphan. If this option is true the pivot of the child
	becomes the new origin for this node. Ie it is exported
	as if the origin is at (0,0,0)
# all at root:
	All objects use their pivots as origin.
# remove local scale:
	If the object is scaled, the scaling is applied to the
	vertices, and removed from the exported matrix (similar
	to reset transform).
# prescale all with:
	You can define a factor that is used to scale the whole
	scene uniformly.
	
Only For Model
# optimize:
	The model's vertices and triangles are reordered for
	faster rendering. 
## generate strips:
	When set the software exports the geometry as
	triangle strips, which sometimes can make it 
	even more efficient to render geometry.
# compute tangents:
	Computes tangent vectors for normal mapping and
	splits the vertices if needed, so less
	artefacts appear.
## as local mirrors:
	The tangent vectors are actually mirror plane normals
	used to support mirrored localspace normal maps. All
	overlapping UV charts that are "mirrored" must be outside
	of the [0,1] UV Space and the fractional part of the UV
	coordinate must match the "inner" reference.
	That means only one "reference" UV chart is inside, 
	while the mirrored are outside and offset by 1.0 
	along U or V or both.
## tangent:
	When regular tangents are exported this is the cosine
	angle tolerance for splits (experiment to control
	vertex duplication/artefacts)
## binormal:
	Same as above but for binormal.

Only for Animation
# key every nth:
	Instead of using the key's timecode, every 
	n-frames a snapshot is taken from the scene.



Bitmaps
-------
The bitmap name is used as texture name, not the filename
If the bitmap name contains no filename extensions the filename 
is copied to the bitmap name.
This was done to allow bitmap names such as "materials/decal.mtl", 
which can't be used as bitmap files

The first BitmapTexmap found (typically it's diffusemap) will be used. With a recursion
depth of 1 those bitmaps are searched within submaps.

Illustration of how bitmaps are found.

recursion
depth:		0				1
diffuse =	bitmap (1st)
bumpmap =	Normal Bump		bitmap (2nd)
							bitmap (3rd)


Materials
---------
if your materialname contains ".shd" the materialname is interpreted as shader file.
An automatic luxinia material will be generated which looks like this:
"MATERIAL_AUTO:<3dsmax materialname>|<bitmapname 0>|<bitmapname 1>|..."
every "map" that has a bitmap will be added to this list.
Bitmaps are searched as mentioned above.

Mesh
----
Skinned objects (pyhsique/skin) should not have Multi-Materials.


PROVIDED AS IS, NO GUARANTEES, NO WARRANTIES, USE AT OWN RISK, MIGHT CRASH...


Misc
----

MaxScript:
The Exporter can be accessed from maxscript with f3dexporter interface


changelog:
1.2: bugfixes with multi-material export
1.3: several new functions: 
  remove local scale (scaling is baked into meshes and output keys/matrices contain no scaling)
  prescale scene (everything is scaled by a user factor)
  orphans at origin (if checked and node's parent is not exported
    then node will be positioned at origin)
1.4: tangent creation and optimizing added, as well as bugfixes with the checkboxes and
  multimaterials
1.5: "MATERIAL_AUTO" string generation, bugfixes with optimization/tangents
1.6: bugfixes with tangent space ... again and again ;)
1.7: bugfix with memory issue when exported mesh was too big
1.8: exports F3D version 2.6, multi-material fixes (needs luxinia >= 0.96)
1.8-64: 64-bit version of the plugin
1.9: added "as local mirrors" options for tangents, and "all at origin"
	renamed "orphans as root" to "orphans at origin" (3dsmax 2009 support)



LUXINIA COL Exporter
====================

A maxscript to export collision geometry. Not tested/used alot. 
But UtilFunctions inside luxinia can load it.