This Interface provides access to the Batch Processing feature of the ProOptimizer modifier.
Available in 3ds Max 2010 and higher.
Note: The properties and methods listed below do NOT change the settings of the Batch Optimization dialog used in interactive mode. They affect the MAXScript Batch Optimizer which is executed using the BatchProOptimizer.batch() method call. This means that you can get and set these properties and process your files using your own MAXScript tool, but the interactive version of the Batch ProOpimizer will keep its own settings and can be used independently.
Interface: BatchProOptimizer
Properties:
BatchProOptimizer.SourceFileMode : integer : Read|Write
Get/set the internal value equivalent to the index of the "Source Directory" radio buttons selection.
Possible values are:
0 - File Selection - uses the files array specified via the BatchProOptimizer.SourceFileFiles property.
1 - Current Directory
2 - Selected Directory
BatchProOptimizer.SourceFileFiles : filename by value array : Read|Write
Get/set the array of source files to process when the .SourceFileMode property is set to 0. Default is #().
BatchProOptimizer.SourceFileDir : string : Read|Write
Get/set the source directory to process when the .SourceFileMode property is set to 2. Default is ""
BatchProOptimizer.SourceFileSubDir : boolean : Read|Write
Get/set the state of the internal option equivalent to the "Include Subdirectories" checkbox.
BatchProOptimizer.OptimizationLevelMode : integer : Read|Write
Get/set the internal value equivalent to the Optimization Level Mode radio buttons selection.
Possible values are:
0 - Predefined Vertex %
1 - Automatic Vertex % (default)
BatchProOptimizer.OptimizationLevel1 : integer : Read|Write
Get/set the value equivalent to the first optimization level value. Default value is 25.
BatchProOptimizer.OptimizationLevel2 : integer : Read|Write
Get/set the value equivalent to the second optimization level value. Default value is 50.
BatchProOptimizer.OptimizationLevel3 : integer : Read|Write
Get/set the value equivalent to the third optimization level value. Default value is 65.
BatchProOptimizer.OptimizationLevel4 : integer : Read|Write
Get/set the value equivalent to the fourth optimization level value. Default value is 75.
BatchProOptimizer.OptimizationLevel5 : integer : Read|Write
Get/set the value equivalent to the fifth optimization level value. Default value is 90.
BatchProOptimizer.OptimizationLevelSteps : integer : Read|Write
Get/set the value equivalent to the "Optimization Levels" value. Default value is 9.
BatchProOptimizer.OptimizeBordersMode : integer : Read|Write
Get/set the internal value equivalent to the Optimize Borders mode radio buttons.
Possible values:
0 - Crunch Borders
1 - Protect Borders (default)
2 - Exclude Border
BatchProOptimizer.OptimizeHidden : boolean : Read|Write
Get/set the internal value corresponding to the "Optimize Hidden Objects" checkbox.
BatchProOptimizer.MergePoints : boolean : Read|Write
Get/set the internal value corresponding to the "Merge Vertices" checkbox.
BatchProOptimizer.MergePointsThreshold : float : Read|Write
Get/set the internal value corresponding to the "Merge Vertices Threshold" value.
BatchProOptimizer.MergeFaces : boolean : Read|Write
Get/set the internal value corresponding to the "Merge Faces" checkbox.
BatchProOptimizer.MergeFacesThreshold : float : Read|Write
Get/set the internal value corresponding to the "Merge Faces Threshold" value.
BatchProOptimizer.KeepMaterialBoundaries : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep Material Boundaries" checkbox.
BatchProOptimizer.KeepTexture : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep Textures" checkbox.
BatchProOptimizer.KeepUVBoundaries : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep UV Boundaries" checkbox.
BatchProOptimizer.UVTolerance : float : Read|Write
Get/set the internal Floating Point value equivalent to the "UV Tolerance (0.0 to 1.0)" field. Default is 0.0.
BatchProOptimizer.KeepVertexColors : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep Vertex Colors" checkbox. Default is false.
BatchProOptimizer.KeepVertexColorsBoundaries : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep VC Boundaries" checkbox. Default is true, but is only used if .KeepVertexColor is true.
BatchProOptimizer.VertexColorsTolerance : integer : Read|Write
Get/set the internal integer value equivalent to the "RGB Tolerance (0 to 255)" field. Default is 128.
BatchProOptimizer.SymmetryMode : integer : Read|Write
Get/set the internal integer value equivalent to the Symmetry Options mode radio buttons selection.
Possible values are:
0 - No Symmetry (default)
1 - XY Symmetry
2 - YZ Symmetry
3 - XZ Symmetry
BatchProOptimizer.SymmetryTolerance : integer : Read|Write
Get/set the internal integer value equivalent to the "Tolerance (0 to 100%)" field's value.
BatchProOptimizer.KeepNormals : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Keep Normals" checkbox.
BatchProOptimizer.NormalMode : integer : Read|Write
Get/set the internal integer value equivalent to the Normals mode radio buttons selection.
Possible values are:
0 - Crunch Normals
1 - Protect Normals (default)
2 - Exclude Normals
BatchProOptimizer.NormalThreshold : float : Read|Write
Get/set the internal float value equivalent to the "Normal Threshold" field's value.
BatchProOptimizer.CompactFaces : boolean : Read|Write
Get/set the internal value corresponding to the "Favor Compact Faces" checkbox.
BatchProOptimizer.PreventFlippedNormals : boolean : Read|Write
Get/set the internal value corresponding to the Prevent Flipped Normals checkbox.
BatchProOptimizer.DestFileNameMode : integer : Read|Write
Get/set the internal integer value equivalent to the File Name Mode radio buttons selection.
Possible values are:
0 - Number by order of creation (scene1, scene2, scene3...)
1 - Number by optimization level (scene25, scene50, scene75...)
BatchProOptimizer.AutoRename : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Auto rename duplicate files" checkbox.
BatchProOptimizer.DestFileNamePrefix : string : Read|Write BatchProOptimizer.DestFileNameSuffix : string : Read|Write
BatchProOptimizer.DestFolderMode : integer : Read|Write
Get/set the internal integer value equivalent to the Optimized Files Directory mode radio buttons selection.
Possible values are:
0 - In the same directory as the source files
1 - In a subdirectory of the source files
2 - In the selected directory (default)
BatchProOptimizer.DestFolderName : string : Read|Write
Get/set the name of the destination folder to use when .DestFolderMode is set to 1 or 2. Default is ".\Results" which is a relative directory to the currently optimized file's path.
BatchProOptimizer.RecreateFolderTree : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Re-create directory Tree" checkbox.
BatchProOptimizer.DestFormatMode : integer : Read|Write
Get/set the internal integer value equivalent to the Optimized Files Format mode radio buttons selection.
Possible values are:
0 - Keep source file format if possible, otherwise convert to selected format (default)
1 - Convert to the selected format
BatchProOptimizer.DestFormatExt : string : Read|Write
Get/set the internal string vale defining the file format extension to use. Default is ".obj". Note that the Batch Optimizer uses a drop-down list in the User Interface in interactive mode.
BatchProOptimizer.LogFilePath : string : Read|Write
Get/set the file name of the log file. Default is "" (no log).
BatchProOptimizer.ApplyModifier : boolean : Read|Write
Get/set the internal Boolean value equivalent to the "Apply Modifier" checkbox in the Utility's User Interface. When set to true, ProOptimizer modifiers will be added to the objects in the batch-processed scenes. When set to false, only existing modifiers will be used without adding new ones.
Methods:
<void>BatchProOptimizer.batch()
Performs the batch optimization according to the settings specified using the above properties.