Python (What's New in 2026.2 Update)
Python Hooks
An example of the usage of the isSnapshot boolean available in the post_export_asset hook has been added in /opt/Autodesk/<version>/python_utilities/examples.
The following python hooks previousy available in /opt/Autodesk/<version>/python/ have been deprecated and replaced by the usage of the /opt/Autodesk/cfg/batch.cfg file in the Centralised Components workflow.
hook.py
timeline_default_gap_bfx_name
batch_hook.py
batch_default_group_pathbatch_default_iteration_pathbatch_default_iteration_namebatch_default_render_node_namebatch_default_write_file_node_name
Python API
PyClipNode
| Command | Type | Description |
|---|---|---|
<PyClipNode>.head_media |
Attribute | Used set or get the Head Media option. One of the following must be passed as the argument when the attribute is set:
|
<PyClipNode>.gap_media |
Attribute | Used set or get the Gap Media option. One of the following must be passed as the argument when the attribute is set:
|
<PyClipNode>.tail_media |
Attribute | Used set or get the Head Media option. One of the following must be passed as the argument when the attribute is set:
|
<PyClipNode>.timing_offset |
Attribute | Used set or get the Timing Offset. An integer number must be passed as an argument. |
<PyClipNode>.locked_frame |
Attribute | Used to get or set the Locked frame. One of the following must be passed as the argument when the attribute is set:
|
<PyClipNode>.version_uids |
Read-Only Property | Used to list the versions available for a Clip node. |
<PyClipNode>.version_uid |
Read-Only Property | Used to get the current version of a Clip node. |
<PyClipNode>.set_version_uid() |
Function | Used to set a version for a clip node. A valid version uid, part of the uids returned in the output of the version_uids read-only property, must be passed as an argument. |
Example
# Select a version for the currently clip node
flame.batch.current_node.get_value().set_version_uid("v01")
# Set the Timing Offset of the current clip node to 12 and lock the frame 1005
clip = flame.batch.current_node.get_value()
clip.timing_offset = 12
clip.batch.current_node.get_value().locked_frame = 1005
PyNode
| Command | Type | Description |
|---|---|---|
<PyNode>.cache_range() |
Function | Used to cache frames for a node. Integer numbers can be passed as arguments to define the start and end frames when caching only a range. If no arguments are set, all the frames are cached. |
Example
# Set a range of frames to be cached for the currently selected node
flame.batch.current_node.get_value().cache_range(10, 21)
PyRenderNode
| Command | Type | Description |
|---|---|---|
<PyRenderNode>.destination |
Attribute | A third argument representing the destination reel can be set when the mode is set to Reel Groups. One of the following must be passed:
Note: "Default Media Panel Option" can also be set to select the default reel defined in the Media Panel System Preferences. |
Example
# Set the destination of a new Render node to the bottommost reel of a Reel Groups named "sh010"
rg = flame.projects.current_project.current_workspace.desktop.create_reel_group("sh010")
render = flame.batch.create_node("Render")
render.destination = ("Reel Groups", rg.name.get_value(), "Bottommost Reel")
PySegment
| Command | Type | Description |
|---|---|---|
<PySegment>.version_uids |
Read-Only Property | Used to list the versions available for a timeline segment. |
<PySegment>.version_uid |
Read-Only Property | Used to get the current version of a timeline segment. |
<PySegment>.set_version_uid() |
Function | Used to set a version for a timeline segment. Two arguments must be passed: version_uid and scope. The former is mandatory, the latter is optional. Follow Source Sharing is applied when the scope is not defined. version_uid: version_uid must be a valid version uid returned in the output of the version_uids read-only property. scope: Used to define the scope of the changes.
|
Example
# Select a version for the currently selected segment
flame.timeline.current_segment.set_version_uid("v01")
PyTypeLayer
| Command | Type | Description |
|---|---|---|
<PyTypeLayer>.opacity |
Attribute | Used to get or set the layer Opacity. A float number between 0.0 and 100.0 must be passed as an argument when the attribute is set. |
Example
# Create a new layer in Type and set its opacity to 50.0%
ty = flame.batch.create_node("Type")
ty_layer = ty.add_layer("Left")
ty_layer.text = "This was added using the Python API."
ty_layer.opacity = 50.0
PyWriteFileNode
| Command | Type | Description |
|---|---|---|
<PyWriteFileNode>.destination |
Attribute | A third argument representing the destination reel can be set when the mode is set to Reel Groups. One of the following must be passed:
Note: "Default Media Panel Option" can also be set to select the default reel defined in the Media Panel System Preferences. |
Example
# Set the destination of the Add to Workspace option of new Write File node to the bottommost reel of a Reel Groups named "sh010"
rg = flame.projects.current_project.current_workspace.desktop.create_reel_group("sh010")
write = flame.batch.create_node("Write File")
write.destination = ("Reel Groups", rg.name.get_value(), "Bottommost Reel")
