Difference between revisions of "Nif Optimization"
→Command Line Options: reorganized a bit; added a few new options
imported>Amorilia (updated nifoptimize.py -> niftoaster.py optimize) |
imported>Amorilia (→Command Line Options: reorganized a bit; added a few new options) |
||
Line 90: | Line 90: | ||
The most important command line options are listed here. For a complete list use the '-h' option. | The most important command line options are listed here. For a complete list use the '-h' option. | ||
====Simple Options==== | |||
For most use cases, these options will suffice. | |||
;-x ''blocktype'' | ;-x ''blocktype'' | ||
:Exclude block type ''blocktype'' from optimization. For example, if you type | :Exclude block type ''blocktype'' from optimization. For example, if you type | ||
Line 100: | Line 100: | ||
python.exe Scripts\niftoaster.py -x NiTriStrips -x NiMaterialProperty optimize C:\nifoptimize | python.exe Scripts\niftoaster.py -x NiTriStrips -x NiMaterialProperty optimize C:\nifoptimize | ||
:will prevent NiTriStrips to be optimized, and will also prevent duplicate NiMaterialProperty blocks to be merged. | :will prevent NiTriStrips to be optimized, and will also prevent duplicate NiMaterialProperty blocks to be merged. | ||
;-i ''blocktype'' | |||
:Only optimize block type ''blocktype''. For example, if you type | |||
python.exe Scripts\niftoaster.py -i NiTriStrips optimize C:\nifoptimize | |||
:then the script will only attempt to optimize NiTriStrips blocks (that is, removing duplicate vertices, restripifying, reskinning, and so on). You can accumulate this option to include multiple block types. If not specified, then all block types are included except those listed with the '''-x''' option. | |||
;-h | |||
:Show all command line options with brief help. | |||
====Advanced Options==== | |||
These options are mainly useful for debugging. | |||
;-r | |||
:Raise exception on errors during optimization. The desired behaviour is simply to print a warning on errors, but continue with the next file nevertheless. If you want the script to halt when it encounters an error, use this option. Mainly useful for debugging. | |||
;--noninteractive | |||
:Do not ask for confirmation before optimizing all files. Usually, you do not want to use this option, but when you have to run the optimizer many times on the same file for debugging purposes, then this might save you some time. | |||
;--dry-run | |||
:Run the optimizer but save the result to a temporary file instead of overwriting the original files. Again, only useful for debugging. | |||
Good luck, and happy optimizing! | Good luck, and happy optimizing! |