The Open Asset Importer Lib 6.0.2
The official Open-Asset-Importer-Library Repository. Loads 40+ 3D-file-formats into one unified and clean data structure.
Loading...
Searching...
No Matches
Common parameters

The parameters described on this page are commonly used by almost every assimp command. They specify how the library will postprocess the imported data. This is done by several configurable pipeline stages, called 'post processing steps'. Below you can find a list of all supported steps along with short descriptions of what they're doing.
Programmers: more information can be found in the aiPostProcess.h header.

ParameterLong parameterDescription
-ptv–pretransform-verticesMove all vertices into worldspace and collapse the scene graph. Animation data is lost. This is intended for applications which don't support scenegraph-oriented rendering.
-gsn–gen-smooth-normalsComputes 'smooth' per-vertex normal vectors if necessary. Mutually exclusive with -gn
-gn–gen-normalsComputes 'hard' per-face normal vectors if necessary. Mutually exclusive with -gsn
-cts–calc-tangent-spaceIf one UV channel and normal vectors are given, compute tangents and bitangents
-jiv–join-identical-verticesOptimize the index buffer. If this flag is not specified all vertices are referenced once.
-rrm–remove-redundant-materialsRemove redundant materials from the imported data.
-fd–find-degeneratesFind and process degenerates primitives.
-slm–split-large-meshesSplit large meshes over a specific threshold in smaller sub meshes. The default vertex & face limit is 1000000
-lbw–limit-bone-weightsLimit the number of bones influencing a single vertex. The default limit is 4.
-vds–validate-data-structurePerforms a full validation of the imported data structure. Recommended to avoid crashes if an import plugin produces rubbish
-icl–improve-cache-localityImprove the cache locality of the vertex buffer by reordering the index buffer to achieve a lower ACMR (average post-transform vertex cache miss ratio)
-sbpt–sort-by-ptypeSplits meshes which consist of more than one kind of primitives (e.g. lines and triangles mixed up) in 'clean' submeshes.
-lh–convert-to-lhConverts the imported data to left-handed coordinate space
-fuv–flip-uvFlip UV coordinates from upper-left origin to lower-left origin
-fwo–flip-winding-orderFlip face winding order from CCW to CW
-ett–evaluate-texture-transformEvaluate per-texture UV transformations (e.g scaling, offset) and build pretransformed UV channels
-guv–gen-uvcoordsReplace abstract mapping descriptions, such as 'spherical' or 'cylindrical' with proper UV channels
-fixn–fix-normalsRun a heuristic algorithm to detect meshes with wrong face winding order/normals.
-tri–triangulateTriangulate poylgons with 4 and more points. Lines, points and triangles are not affected.
-fi–find-instancesSearch the data structure for instanced meshes and replace them by references. This can reduce vertex/face counts but the postprocessing-step takes some time.
-og–optimize-graphSimplify and optimize the scenegraph. Use it with care, all hierarchy information could be lost. Animations remain untouched.
-om–optimize-meshesOptimize mesh usage. Meshes are merged, if possible. Very effective in combination with –optimize-graph
-tuv–transform-uv-coordsWill transform uv-coordinates if possible.
-fid–find-invalid-dataWill look for invalid data in the imported model structure.
-db–deboneRemoves nearly losslessly or according to a configured threshold bones from the model.
-sbc–split-by-bone-countSplit meshes with too many bones. Necessary for our (limited) hardware skinning shader.

For convenience some default postprocessing configurations are provided. The corresponding command line parameter is -c<name> (or –config=<name>).

NameDescriptionList of steps executed
fastFast post processing config, performs some essential optimizations and computes tangents-cts, -gn, -jiv, -tri, -guv, -sbpt
defaultBalanced post processing config; performs most optimizations-cts, -gsn, -jiv, -icl, -lbw, -rrm, -slm, -tri, -guv, -sbpt, -fd, -fiv
fullFull post processing. May take a while but results in best output quality for most purposes-cts, -gsn, -jiv, -icl, -lbw, -rrm, -slm, -tri, -guv, -sbpt, -fd, -fiv, -fi, -vds -om

The -tuv, -ptv, -og flags always need to be enabled manually.

There are also some common flags to customize Assimp's logging behaviour:

NameDescription
-l or –show-logShow log file on console window (stderr)
-lo<file> or –log-out=<file>Streams the log to <file>
-v or –verboseEnables verbose logging. Debug messages will be produced too. This might decrease loading performance and result in very long logs ... use with caution if you experience strange issues.