Go to: Synopsis. Return value. Flags. Python examples.

Synopsis

thumbnailCaptureComponent( [string] , [capture=boolean], [capturedFrameCount=boolean], [closeCurrentSession=boolean], [delete=boolean], [endFrame=int], [fileDialogCallback=string], [isSessionOpened=boolean], [launchedFromOptionsBox=boolean], [previewPath=boolean], [removeProjectThumbnail=string], [save=string], [startFrame=int])

Note: Strings representing object names and arguments must be separated by commas. This is not depicted in the synopsis.

thumbnailCaptureComponent is NOT undoable, queryable, and NOT editable.

This command is used to generate a thumbnail/playblast sequence from the scene.

Return value

None

In query mode, return type is based on queried flag.

Flags

capture, capturedFrameCount, closeCurrentSession, delete, endFrame, fileDialogCallback, isSessionOpened, launchedFromOptionsBox, previewPath, removeProjectThumbnail, save, startFrame
Long name (short name) Argument types Properties
capture(c) boolean create
Create a new component to capture a sequence of image for the current scene.
capturedFrameCount(cfc) boolean query
Query only. Return the number of frames that have been captured.
closeCurrentSession(ccs) boolean create
Delete the current thumbnail component (preview image will be destroyed).
delete(d) boolean create
Delete the generated image sequence and preview for the current capture session.
endFrame(ef) int createquery
Set the end captured frame. Only valid when the -c/capture flag is set. If -sf/startFrame is set and not -ef/endFrame, or if endFrame is smaller than startFrame, endFrame will be automatically set to startFrame.
fileDialogCallback(fdc) string create
MEL only. Set the callback file dialog which is called after the capture component window has been closed. Only valid when the -c/capture flag is set.
isSessionOpened(iso) boolean query
Returns true if a thumbnail/playblast capture session is currently running (already opened and still not cancelled/saved).
launchedFromOptionsBox(lfo) boolean query
Returns true if the thumbnail capture component was launched through the options dialog box, else false.
previewPath(pp) boolean query
Returns the generated preview path (the first frame of generated sequence resized to 100x100 px).
removeProjectThumbnail(rpt) string create
Remove all captured thumbnail/playblast from the given project file path.
save(s) string create
Save the generated image sequence for the given file to disk. The file path must be an absolute path.
startFrame(sf) int createquery
Set the start captured frame. Only valid when -c/capture flag is set.

Flag can appear in Create mode of command Flag can appear in Edit mode of command
Flag can appear in Query mode of command Flag can have multiple arguments, passed either as a tuple or a list.

Python examples

import maya.cmds as cmds

import maya.cmds as cmds


#    Launch an option box used to capture the scene between frame 20 and 60


cmds.thumbnailCaptureComponent(capture=True, startFrame=20, endFrame=60)


#    Save the generated image sequence for "mesh.mb"


cmds.thumbnailCaptureComponent(save='C:/maya/projects/default/scenes/mesh.mb')


#    Delete generated thumbnails for current capture session

cmds.thumbnailCaptureComponent(delete=True)


#    Return the path of generated sequence preview.


cmds.thumbnailCaptureComponent(q=True, previewPath=True)
# Result: C:/Users/perradw/Documents/maya/projects/default/images/.MayaTempCaptureComponent/tmp.preview #