Project#
- class pybmd.project.Project(project)[source]
Bases:
object
Project Object
Methods
__init__
(project)add_color_group
(group_name)Creates a new ColorGroup.
Adds a render job based on current render settings to the render queue.
Deletes all render jobs in the render queue.
delete_color_group
(color_group)Deletes the given color group and sets clips to ungrouped.
delete_render_job
(job_id)Deletes render job for input job id (string).
delete_render_preset
(preset_name)Delete render preset by provided name
export_current_frame_as_still
(file_path)Exports current frame as still to supplied filePath.
Returns a list of all group objects in the timeline.
Returns a dict with currently selected format 'format' and render codec 'codec'.
Returns the render mode: 0 - Individual clips, 1 - Single clip.
Returns the currently loaded Timeline.
Returns the Gallery object.
Returns the MediaPool object.
get_name
()Return project name
Returns a list of presets and their information.
Returns a list of names of all Quick Export render presets.
get_render_codecs
(render_format)returns a dict with render codecs for a given render format.
Returns a dict (format -> file extension) of available render formats.
Returns a list of render jobs and their information.
get_render_job_status
(job_id)Returns a dict with job status and completion percentage of the job by given jobId (string).
Returns a list of render presets and their information.
get_render_resolutions
(format, codec)Returns list of resolutions applicable for the given render format (string) and render codec (string).
get_setting
([setting_name])Returns value of project setting (indicated by setting_name, string).
Returns Timeline at the given index, 1 <= idx <= project.get_timeline_count()
Returns the number of timelines currently present in the project.
Returns unique id of the project Object.
Inserts the media specified by mediaPath (string) with startOffsetInSamples (int) and durationInSamples (int) at the playhead on a selected track on the Fairlight page.
Returns True if rendering is in progress.
load_burn_in_preset
(preset_name)Loads user defined data burn in preset for project when supplied presetName (string).
load_render_preset
(preset_name)Sets a preset as current preset for rendering if preset_name (string) exists.
Refreshes LUT List
render_with_quick_export
(preset_name, param_dict)Starts a Quick Export render using the specified preset name and parameter dictionary.
save_as_new_render_preset
(preset_name)Creates new render preset by given name if preset_name(string) is unique.
set_current_render_format_and_codec
(format, ...)Sets given render format (string) and render codec (string) as options for rendering.
set_current_render_mode
(render_mode)Sets the render mode.
set_current_timeline
(timeline)Sets given Timeline as current timeline for the project.
set_name
(project_name)Sets project name if given project_name (string) is unique.
set_preset
(preset_name)Sets preset by given preset_name (string) into project.
set_render_settings
(render_setting)Sets given settings for rendering.
set_setting
(setting_name, setting_value)Sets value of project setting (indicated by setting_name, string).
start_rendering
(job_ids[, is_interactive_mode])Start rendering.
Stops rendering.
- add_render_job() str [source]
Adds a render job based on current render settings to the render queue.
- Returns:
A unique job id (string) for the new render job.
- Return type:
- get_current_render_format_and_codec() dict [source]
Returns a dict with currently selected format ‘format’ and render codec ‘codec’.
- Return type:
- get_current_render_mode() int [source]
Returns the render mode: 0 - Individual clips, 1 - Single clip.
- Return type:
- get_current_timeline() Timeline [source]
Returns the currently loaded Timeline.
- Return type:
Timeline
- get_gallery() Gallery [source]
Returns the Gallery object.
- Return type:
Gallery
- get_media_pool() MediaPool [source]
Returns the MediaPool object.
- Return type:
MediaPool
- get_render_codecs(render_format: str) dict [source]
returns a dict with render codecs for a given render format.
- get_render_formats() dict [source]
Returns a dict (format -> file extension) of available render formats.
- Return type:
- get_render_job_list() list [source]
Returns a list of render jobs and their information.
- Return type:
- get_render_job_status(job_id: str) dict [source]
Returns a dict with job status and completion percentage of the job by given jobId (string).
- get_render_preset_list()[source]
Returns a list of render presets and their information.
- get_render_resolutions(format: str, codec: str) List[dict] [source]
Returns list of resolutions applicable for the given render format (string) and render codec (string).
- get_setting(setting_name: str = '') str [source]
Returns value of project setting (indicated by setting_name, string).
- get_timeline_by_index(idx) Timeline [source]
Returns Timeline at the given index, 1 <= idx <= project.get_timeline_count()
- Return type:
Timeline
- get_timeline_count() int [source]
Returns the number of timelines currently present in the project.
- Return type:
- load_render_preset(preset_name) bool [source]
Sets a preset as current preset for rendering if preset_name (string) exists.
- Return type:
- save_as_new_render_preset(preset_name) bool [source]
Creates new render preset by given name if preset_name(string) is unique.
- Return type:
- set_current_render_format_and_codec(format: str, codec: str) bool [source]
Sets given render format (string) and render codec (string) as options for rendering.
- set_current_timeline(timeline: Timeline) bool [source]
Sets given Timeline as current timeline for the project. Returns True if successful.
- Parameters:
timeline (Timeline)
- Return type:
- set_name(project_name) bool [source]
Sets project name if given project_name (string) is unique.
- Return type:
- set_render_settings(render_setting: RenderSetting) bool [source]
Sets given settings for rendering.
- Parameters:
render_setting (RenderSetting) – RenderSetting object
- Returns:
True if successful.
- Return type:
- set_setting(setting_name: str, setting_value: str)[source]
Sets value of project setting (indicated by setting_name, string).
- start_rendering(job_ids: list, is_interactive_mode=False) bool [source]
Start rendering. Returns True if successful. if job_ids==None render all queued render jobs.
- stop_rendering()[source]
Stops rendering.
- insert_audio_to_current_track_at_playhead(media_path: str, start_offset_in_samples: int, duration_in_samples: int) bool [source]
Inserts the media specified by mediaPath (string) with startOffsetInSamples (int) and durationInSamples (int) at the playhead on a selected track on the Fairlight page.
- load_burn_in_preset(preset_name: str) bool [source]
Loads user defined data burn in preset for project when supplied presetName (string).
- export_current_frame_as_still(file_path: str) bool [source]
Exports current frame as still to supplied filePath.
- get_color_groups_list() List[ColorGroup] [source]
Returns a list of all group objects in the timeline.
- Returns:
a list of all group objects
- Return type:
List[ColorGroup]
- add_color_group(group_name: str) ColorGroup [source]
Creates a new ColorGroup.
- Parameters:
group_name (str) – groupName must be a unique string.
- Returns:
ColorGroup object if successful, otherwise None.
- Return type:
ColorGroup
- delete_color_group(color_group: ColorGroup) bool [source]
Deletes the given color group and sets clips to ungrouped.
- Parameters:
color_group (ColorGroup) – color group object to delete
- Returns:
Return True if successful, otherwise False.
- Return type:
- get_quick_export_render_presets() List[str] [source]
Returns a list of names of all Quick Export render presets.
- render_with_quick_export(preset_name: str, param_dict: Dict[str, Any]) Dict[str, Any] [source]
Starts a Quick Export render using the specified preset name and parameter dictionary.
- Parameters:
- Returns:
A dictionary containing the job status and render time, or an error string if the render failed or was not attempted.
- Return type:
Dict[str, Any]