Click or drag to resize
Ab4d.SharpEngine logo

ModelOptimizer Class

ModelOptimizer is a static class that can be used to optimize a GroupNode by combining meshes that have the same material into one mesh. This can improve performance because less draw calls are required.
Inheritance Hierarchy
SystemObject
  Ab4d.SharpEngine.UtilitiesModelOptimizer

Namespace: Ab4d.SharpEngine.Utilities
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 3.1.9316+94bbd23b55747f096f056a5602f7dd90558b3673
Syntax
C#
public static class ModelOptimizer

The ModelOptimizer type exposes the following members.

Properties
 NameDescription
Public propertyStatic memberAutoGenerateModelNames When true (by default) then the names of the combined MeshModelNodes are automatically generated from the names of the used ModelNodes (using CombinedNamesSymbol between names; plus symbol by default). If the combined name is longer than MaxAutoGenerateModelNameLength then the name is not generated.
Public propertyStatic memberMaxAutoGenerateModelNameLength Defines an integer that defines the maximum length of the automatically generated name for the combined MeshModelNode.
Top
Methods
 NameDescription
Public methodStatic memberOptimize Optimizes the models in the specified GroupNode and returns a new GroupNode with optimized models. Child SceneNodes that cannot be optimized (LineNodes, etc.) are copied to the new GroupNode. This method also flattens the hierarchy of the children.
Top
Fields
 NameDescription
Public fieldStatic memberCombinedNamesSymbol Defines the character that is used when combining names. Plus symbol is used by default.
Top
Remarks

[Missing <remarks> documentation for "T:Ab4d.SharpEngine.Utilities.ModelOptimizer"]

See Also