glmCrowdSimulationExporter

The glmCrowdSimulationExporter  commands exports Golaem simulation CrowdField nodes as Simulation Cache files. This command is called by the Simulation Exporter.
glmCrowdSimulationExporter [-startFrame int] [-endFrame int] [-crowdFieldNode string] [-exportFromCache bool] [-exportCaaOnly bool]

[-scExpName string] [-scExpOutDir string] [-scExpAttrs string]

[-preExportCallback string] [-preExportCallbackLanguage int] [-postExportCallback string] [-postExportCallbackLanguage int]

[-exportScreenshots bool] [-screenshotsDir string] [-screenshotsPrefix string] [-screenshotsSuffix string] [-screenshotsFormat string]

Flags

Global Flags

These parameters are relative to the global Simulation Exporter parameters:

Long name (short name) Argument types Properties Description
-startFrame (-sF) int mandatory start frame from which the simulation will be exported
-endFrame (-eF) int mandatory end frame to which the simulation will be exported
-crowdFieldNode (-cfn) string mandatory, multi-use name of the CrowdField nodes which will be exported
-exportFromCache (-efc) bool   if true, the export process uses Simulation Cache files which have been exported before
-exportCaaOnly (-eco) bool   if true, only the Crowd Assets Association file (.caa) is exported

Simulation Cache Files Flags

These parameters are relative to the Simulation Cache files parameters of the Simulation Exporter:

Long name (short name) Argument types Properties Description
-scExpName (-sn) string mandatory base name of the exported Simulation Cache files
-scExpOutDir (-sod) string mandatory, multi-use directories where the Simulation Cache files will be exported. It is possible to specify one directory per CrowdField (else all the files will be exported in the first specified directory)
-scExpAttrs (-sea) string mandatory, multi-use name of the ppAttributes which values will be exported in the Simulation Cache files

Callback Flags

These parameters are relative to the Simulation Exporter Callback parameters of the Simulation Exporter:

Long name (short name) Argument types Properties Description
-preExportCallback (-prc) string   MEL / Python function to call when the export starts
-preExportCallbackLanguage(-prl) int   Language of the pre-export callback: 0 for MEL, 1 for Python

-postExportCallback(-poc)

string   MEL / Python function to call when the export stops
-postExportCallbackLanguage(-pol) int   Language of the post-export callback: 0 for MEL, 1 for Python

Screenshots Flags

Long name (short name) Argument types Properties Description
-exportScreenshots (-ess) bool   export viewport screenshots
-screenshotsDir (-sdr) string   directory where the screenshots files will be written
-screenshotsPrefix (-spr) string   screenshots file name prefix
-screenshotsSuffix (-ssf) string   screenshots file name suffix (added after the frame number)
-screenshotsFormat (-sfr) string   screenshots file format. Examples of valid formats include: "als", "bmp", "cin", "gif", "iff", "jpg", "png", "tga", "tif". Default is "png"

For a given frame, the screenshot is exported to the file: [screenshotsDir]/[screenshotsPrefix][frameNumber][screenshotsSuffix].[screenshotsFormat]

Return Value

This command returns nothing

MEL Examples

// export Simulation Cache files only between frame 1 and 100
glmCrowdSimulationExporter -startFrame 1 -endFrame 100 -crowdFieldNode "crowdField1" -exportFromCache 0  -scExpAttrs "particleId" -scExpName "testScene" -scExpOutDir "N:/tests/export";

Usage with Maya Batch

To batch export a batch simulation, use the glmBatchCrowdSimulationExporter command