All posts by Igor Ridanovic

DaVinci Resolve Dynamic Text Hack

This Windows app demonstrates DaVinci Resolve external dynamic title generation.

DaVinci Resolve V15 allows Fusion macros to be used on the edit page as title templates. This app generates macros on-the-fly.

The app has two buttons. One generates a date/time stamp at the time the button is pressed. The other button retrieves Bundesliga RSS news (German football league) and formats the headlines as a bottom of the screen crawl.

It is necessary to click each button once before launching Resolve for the first time. Resolve loads the list or templates into the memory only once at start time. Once the templates are loaded we can click the buttons to refresh the templates. The text content of the templates cut into  the timeline is frozen.

Windows executable (8.1 MB)

Python script

Resolve Scripting

DaVinci Resolve 15 public beta added a powerful new feature to its ever expanding toolset. Resolve merged with Fusion VFX software and inherited the Fusion’s scripting capability.

In addition to the existing FuScript, Resolve now has an API that opens up the the color grading application to third party software integration and pipeline automation.

The documentation lists a whole range of methods for creating and structuring projects, importing media, writing and reading metadata, applying color presets, and setting up and rendering timelines.

The API is accessible via Lua or Python. Users can use the built-in console or the native OS command line console to execute commands. But the true power comes from using external scripts or applications to automate tasks in Resolve.

This sample Python script shows the simplicity of the API. It retrieves the currently loaded project’s name once an hour and calls a user supplied presentation function to display the name.

#! /usr/bin/env python

import time

# Import the API module and
# create resolve instance

import DaVinciResolveScript as drs
resolve = drs.scriptapp('Resolve')

projectManager = resolve.GetProjectManager()
project = projectManager.GetCurrentProject()

def presentation(p)
# Supply your own function here
    print 'The current Resolve project name:', p

while True:
   projectName = project.GetName()
   presentation(projectName)
  time.sleep(3600)

Download other sample Resolve Python scripts.

Avid to Resolve Marker Converter

This tool converts Avid Media Composer markers to DaVinci Resolve timeline markers. It also generates a web based document for colorist and client review.

In Media Composer click on the fast menu in the markers window and save the markers in txt format. Upload the file and download the converted EDL file.

In Resolve right click a timeline, select Timelines/Import/Timeline Markers from EDL…, and load the converted marker EDL file.

Continue reading

Resolve Database Backup

This Python script dumps one DaVinci Resolve Postgres database at a time and saves it in the current user’s Documents directory twice a day. The interval is set inside the script itself. The script does not require OS level scheduling.

User controls available inside the script:

  • Backup interval
  • Days to keep old backups
  • Database name
  • Database login information
  • Postgres version number

It is important to set the correct Postgres version for the script to run.

Usage is the same in Windows and OS X. Execute the script at any time, or add it to the startup programs for automatic start. In Windows you can rename the extension to .pyw to suppress the console window.

Python 2.7 in required in Windows. OS X already comes with Python, but you need to associate the .py extension with the Python Launcher if you want to execute the script by double clicking. The script currently does not support the Linux version of Resolve.

Download pgrbackup.py.

GitHub: https://github.com/IgorRidanovic/Resolve-backup-Postgres

If you are running Resolve Disc Database instead of Postgres database use this backup tool.

DaVinci Resolve 12 Disk Database Backup Tool

A bug in the new projects Disk Database in Resolve 12 can invalidate the project XML which can lead to catastrophic loss of timelines.

This Python script zips up the database and saves it in the current user’s Documents directory every two hours. The interval is set inside the script itself. The script does not require OS level scheduling.

Usage is the same in Window,  OS X, and Linux. Run the script after login, or add it to the startup programs for automatic start. In Windows you can rename the extension to .pyw to suppress the console window.

You will need to install Python 2.7 in Windows. OS X and Linux already come with Python, but you need to associate the .py extension with the Python Launcher in OS X if you want to execute the script by double clicking. CentOS 7 seems to be missing Tkinter module which you can install manually with yum install tkinter.

Download: resolvebackup.py.

GitHub: https://github.com/IgorRidanovic/resolve-backup

Avid Project Setup Automation

Createproject Python script is used for Media Composer finishing project preparation. It automatically creates:

  1. Custom named Media Composer project with custom bins.
  2. Custom named Avid MediaFiles/MXF media storage directory.
  3. Custom named ancillary storage path for elements.

In addition, createproject.py backs up the bin containing the locked sequence to the ancillary storage and copies it to SEQ Avid bin inside the project. Upon completion createproject.py sends emails to one or more recipients.

The user configurable template project contains bins used for the project creation.

The script requires Python 2.7x install in Windows. Python is installed in OS X by default.  Minimal user configuration of the script is required.

Download createproject.py

Usage

The script is suited for episodic show use. The bin should contain no spaces and be named as:

<SHOW INITIALS>_<EPISODE NUMBER>[AnyText].avb

An example valid name is: ABC_101_FinalLocked.avb.

Windows

Drag-and-drop Avid bin onto the script icon.

OS X

  1. Double click the script icon.
  2. Drag-and-drop Avid bin onto the Terminal window
  3. Press Enter

 

SMPTE Timecode Python Module

The SMPTE timecode Python module converts SMPTE timecode to frame count and frame count to SMPTE timecode. It accepts any arbitrary frame rate with 29.976 reserved for drop frame calculations.

ValueError exception is raised in case of a malformed timecode or a timecode where frame column value exceeds the specified frame rate.

Download SMPTE.py

Sample Usage

import SMPTE

fps = 30

framecount = smpte.fromtc('11:22:38:12', fps)
print framecount

timecode = smpte.totc(92473, 30)
print timecode

Avid Media Composer Crash Alert

This script will send emails or text messages to an unlimited number of recipients when Avid Media Composer running on Windows or OS X is terminated by crash or a user action.

The script requires Python 2.7x install in Windows. Python is installed in OS X by default.

Download MCalert

Windows

  1. Open the script in text editor and configure email settings.
  2. Double click the script. Media Composer will launch.

OS X

  1. Open the script in text editor and configure email settings.
  2. Select mcalet.py and press Command – I. Enable executive permission.
  3. Double click the script. Media Composer will launch.