×
Меню
Индекс

Scene Graph Optimization

Это относится к 4.2 модулю экспорта!
В 4.0 этих опций нет!!!
 
ФФЕ 4.2 необходимая часть для экспорта IK анимаций!

 Выдержка из оригинальной справки. (NDL Gamebryo 1.1)
 
Description
This plug-in optimizes the scene graph to reduce memory overhead and traversal time. There are a myriad of optimization options that can be set for this plug-in.
 
Options
Remove duplicate properties
Function Performed: Ensures that all duplicate properties in the scene are shared.
NiOptimize Function Called: RemoveDupProperties
Explanation: All material and texturing properties are exported as unique objects, even if they are the same property in 3ds max or Maya. This function ensures that all identical properties in the scene are shared to reduce memory overhead. Several other optimization options will not be as effective if this option is not checked. This optimization option should always be selected.
 
Remove bad NiTexturing properties
Function Performed: Removes NiTexturingProperty properties with no image data in the scene and those that use a nonexistent set of texture coordinates.
NiOptimize Function Called: RemoveBadTexturingProps
Explanation: This function cleans up after some situations that can occur due to the way the artist manipulates the textures and the way 3ds max exposes the data to the Gamebryo 3ds max Plug-in. This function is not trying to correct an artist mistake. Instead, it optimizes the content received from the 3ds max SDK for better performance and to reduce memory overhead. This optimization option should always be selected.
 
Remove multi-material nodes
Function Performed: Removes all multi-material nodes in the scene. Multi-material nodes are created by some modeling packages to accommodate multiple materials on an object. They are usually not needed and can be removed.
NiOptimize Function Called: RemoveMultiMtlNodes
Explanation: When a multi-sub object material is used on an object in 3ds max, that object is split up into multiple objects upon export, one for each material. These multiple objects are placed under a common parent node, which is given the name "__NDL_MultiMtl_Node". This node has no transforms, controllers, or properties on it and serves no real purpose other than to indicate that its children used to be a single object. This optimization function removes all such nodes to reduce object overhead. It should always be selected.
 
Remove childless nodes
Function Performed: Removes all nodes in the scene that have no children.
NiOptimize Function Called: RemoveChildlessNodes
Explanation: Gamebryo only renders leaf objects in the scene graph. A NiNode has no visible geometry and thus is irrelevant to rendering. Thus, a node with no children is entirely useless unless specifically reserved for application use later. To reduce object overhead, this function removes all NiNodes in the scene that have no children and appear not to be used. A node can be retained if the string "NiOptimizeKeep" is placed in its user-defined properties in 3ds max or in a string property in Maya. A childless node will be removed even if it has time controllers attached to it. If you want the node to be kept, you must tag the node with "NiOptimizeKeep".
 
Remove single-child nodes
Function Performed: Removes all nodes in the scene that have only one child, propagating any properties, transforms and name to that child. The name will not be propagated if the child has an "NiOptimizeKeep" tag.
NiOptimize Function Called: RemoveSingleChildNodes
Explanation: A geometry object in 3ds max is actually represented internally by a node with a geometry child. That is what gets exported. Thus, if you create a box in 3ds max named "Box01", after exporting you will have an NiNode named "Box01" with the transforms of the box. That node will have a single NiTriShape child named "Box" with identity transforms. Usually only the actual geometry object is needed, since the geometry appears to be a single object in 3ds max, so this optimization function removes these single-child nodes to reduce object overhead. The name, transforms, and properties of the node are propagated to the child, and the node is removed, with the child being attached to the node's parent. Thus, after running this function, you will have an NiTriShape object named "Box01". If the node has any time controllers attached to it (i.e., it is animated), the node will not be removed. If the child has an "NiOptimizeKeep" tag on it, the name will not be propagated to it.
 
Merge sibling nodes
Function Performed: Merges sibling nodes in the scene. Two nodes will be merged if the following holds: the nodes are sibling nodes, of exact type NiNode, and they have a parent of exact type NiNode, the same properties attached to them, and the same visibility flag. If two nodes can be merged and have different transforms on them, the transforms for both nodes are pushed down to their children before they are merged.
NiOptimize Function Called: MergeSiblingNodes
Explanation: Merging sibling nodes, in conjunction with removing single-child nodes and merging sibling NiTriShape objects, can allow more NiTriShapes to be merged than would be otherwise. The fewer objects in the scene and the more triangles per NiTriShape object, the faster the run-time performance will be.
 
Merge sibling NiTriShape objects
Function Performed: Merges all sibling NiTriShape objects in the scene. Two NiTriShape objects can be merged if the following holds: they have a common parent of exact type NiNode, the same number of properties, the same set of property pointers, the same number of texture sets, no time controllers attached, different NiGeometryData pointers, the same AppCulled flag value, and they both/neither have vertices, normals, textures, and colors. Two NiTriShape objects will not be merged if either of them has any extra data attached.
NiOptimize Function Called: MergeSiblingTriShapes
Explanation: This function merges sibling NiTriShape objects to increase the triangle/NiTriShape ratio and reduce object overhead. Its effectiveness is vastly reduced if duplicate properties and single-child nodes are not removed and sibling nodes are not merged.
 
Do not merge alpha-blended NiTriShape objects
Function Performed: If this option is checked, merging does not occur below nodes with an NiAlphaProperty attached when alpha blending is enabled or sorters are allowed.
Explanation: Merging two NiTriShape objects that are intended to be sorted by an alpha sorter may cause the sorter to be unable to correctly order the NiTriShape objects when rendering. This situation should be avoided, but it can be allowed by unchecking this option.
 
Optimize NiTriShape objects
Function Performed: Removes degenerate triangles and collapses vertices of all NiTriShape objects in the scene, deleting them if all their triangles are degenerate.
NiOptimize Function Called: OptimizeTriShapes
Explanation: The problems that this optimization option fixes should not occur naturally in datasets exported from 3ds max or Maya. However, after merging NiTriShape objects or on modified datasets, it can be useful. There is no harm in leaving this option turned on at all times to ensure optimized NiTriShape data.
 
Remove extra texture coordinate sets
Function Performed: Removes all texture coordinate sets from geometry in the scene that are not used by any NiTexturingProperty attached to the current or a higher node.
NiOptimize Function Called: RemoveExtraUVSets
Explanation: Like the "Remove bad NiTexturing properties" option, this option optimizes situations that can occur through normal use of 3ds max and Maya. There is no particular situation that it is trying to correct. This optimization option should always be selected.
 
Remove unnecessary normals
Function Performed: Recursively removes normals that are not needed. Will not remove normals from scenes without lights.
NiOptimize Function Called: RemoveUnnecessaryNormals
Explanation: Normals are removed from every object when the following is true: the object has an NiTexturingProperty attached that has a base map and an apply mode of APPLY_REPLACE, or the object has an NiVertexColorProperty attached whose lighting mode is emissive. This optimization option should always be selected.
 
Remove unnecessary NiVisControllers
Function Performed: Removes all NiVisControllers in the scene whose keys all have the same visibility data, updating the visibility flag of their targets.
NiOptimize Function Called: RemoveUnnecessaryVisControllers
Explanation: If a NiVisController has the same visibility data for all its keys, it does not need to exist. This function removes the NiVisController in this situation. This situation can occur quite easily in 3ds max and Maya and is not always due to artist error. This optimization option should always be selected.
 
Remove unnecessary NiLookAtControllers
Function Performed: Removes NiLookAtControllers in the scene if there are no NiKeyframeControllers on either the target or the "Look At" of the controller or above them in the scene graph.
NiOptimize Function Called: RemoveUnnecessaryLookAtControllers
Explanation: An NiLookAtController changes the orientation of its target to always face a particular "Look At" object. If there are no NiKeyframeControllers attached above either the target or the "Look At" in the scene graph, the NiLookAtController is not necessary since nothing will ever move. This function removes the NiLookAtController in this situation.
One way in which this situation might occur is if a target camera is used, but neither the camera nor the target is animated. This optimization option should always be selected.
 
Remove hidden bone geometry
Function Performed: Removes any NiGeometry object in the scene that is a child of a bone and whose AppCulled flag is true.
NiOptimize Function Called: RemoveHiddenBoneGeometry
Explanation: A bone is defined as an object that is pointed to by the bone array of an NiSkinInstance object in the scene graph. This function removes any NiGeometry child of a bone whose AppCulled flag is true (i.e., that is hidden), without exception.
 
Reduce animation keys
Function Performed: Reduces redundant animation keys for all NiKeyframeControllers in the scene. The tolerance specifies a ratio of how far off a key is allowed to be from an interpolation between the two keys on either side of it to still be considered redundant.
NiOptimize Function Called: ReduceAnimationKeys
Explanation: Since both 3ds max and Maya produce copious amounts of keyframes in certain cases (Maya when "baking" IK animations and 3ds max when sampling keyframes), this function can be essential in removing duplicate keyframes. It should be turned on unless there is a specific reason why redundant animation keys should not be removed.
 
Remove unnecessary extra data
Function Performed: Removes extra data strings that are empty or that contain only strings used for temporary conversion purposes. If the Remove "NiOptimizeKeep" tags option is checked, extra data objects that contain the strings "NiOptimizeKeep" and "sgoKeep" are also removed.
NiOptimize Function Called: RemoveUnnecessaryExtraData
Explanation: These strings are removed to free memory. There is no other reason why they need to be removed.
 
Sort children of each node by NiTexturingProperty
Function Performed: Sorts all the children of each node in the scene by the address of the NiTexturingProperty present in their property states. Children with no NiTexturingProperty objects in their property state are sorted first.
NiOptimize Function Called: SortByTexturingProp
Explanation: This function helps somewhat with increasing rendering efficiency. However, the constraints of maintaining the structure of the scene graph limit how optimized it can be.
 
Object Names
 
Remove all object names
Function Performed: Removes the name string from every object and material property in the scene.
NiOptimize Function Called: RemoveNames
Explanation: This function is provided in case names are not needed by an application. Removing the names can slightly reduce the memory overhead but will cause problems with some classes such as NiControllerManager that relies on the presence of object names. You should only remove names if you are positive they are not needed.
 
Name all unnamed objects
Function Performed: Adds unique names to all objects that are unnamed in the scene.
NiOptimize Function Called: NameUnnamedObjects
Explanation: This function prevents any objects from being exported with no name. This option is provided in case an application requires that all objects have names.
 
Skin and Bones Support
Hardware/Software/Both
Function Performed: Specifies the settings for exporting skinning information.
NiOptimize Function Called: OptimizeSkinData
Explanation: These options specify what type of skinning information to export for each platform. For all platforms except the Nintendo GameCube, you have the option to export information for hardware skinning, software skinning, or both. Datasets exported with only information for hardware skinning will not run on graphics hardware that does not support hardware skinning. Datasets exported with both hardware and software skinning information will be hardware accelerated when possible, but can still run on graphics hardware that does not support hardware skinning. You can also specify the number of bones per skin partition here.
 
Weld hardware skin partitions
Function Performed: Elimination of cracks in skinned models.
NiOptimize Function Called: WeldSkin
Explanation: The limited number of bones that can be active when using hardware-accelerated skinning creates the need to ignore certain bone-vertex interactions when the data structures used for hardware-accelerated skinning are created. This can cause cracks to appear on edges shared by triangles in different Gamebryo objects if a bone's influence is ignored in one triangle but not ignored by an adjacent triangle in a different Gamebryo object. The welding code identifies edges where such cracks have been created and eliminates them. In order for this welding to occur, the two objects must have identical world transforms.