Go to: Synopsis. Return value. Related. Flags. MEL examples.
refresh [-currentView] [-fileExtension string] [-filename string] [-force] [-suspend boolean]
refresh is undoable, NOT queryable, and NOT editable.
This command is used to force a redraw during script execution. Normally, redraw is suspended while scripts are executing but sometimes it is useful to show intermediate results for purposes such as capturing images from the screen.If the -cv flag is specified, then only the current active view is redrawn.
None
Long name (short name) | Argument types | Properties | ||
---|---|---|---|---|
-currentView(-cv)
|
|
![]() |
||
|
||||
-fileExtension(-fe)
|
string
|
![]() |
||
|
||||
-filename(-fn)
|
string
|
![]() |
||
|
||||
-force(-f)
|
|
![]() |
||
|
||||
-suspend(-su)
|
boolean
|
![]() |
||
|
![]() |
![]() |
![]() |
![]() |
refresh; // The refresh command can also be used to take a snapshot of the current scene view and // save it as an image file. See example below. // Set up workspace for images in current project string $ws=`workspace -q -fullName`; string $wsp=$ws + "/images"; sysFile -makeDir $wsp; // Prepare unique image name for snapshot string $imageSnapshot = $wsp + "/endSnapshot.jpg"; // Take a snapshot of the viewport and save to file refresh -cv -fe "jpg" -fn $imageSnapshot;