YOU MUST HAVE A PAID COPY OF STUDIO FOR THIS WORK. I'VE ONLY TESTED IT ON 16.1.1.005
So,
I dug into the API. I know there are a lot of complaints about the scant documentation. It's... not so bad IMHO. Don't get me wrong, it could be a LOT better, but it's really not that bad.
This script will be expanded on as time goes on, I may even decide to do a GUI at some point.
This is what I whipped up pretty quick and there aren't a lot of checks for validity yet. Code is commented to death so that people can see what is going on, since there aren't many examples or documentation sets for Resolve.
The API has a lot in it, way more than documented...you just have to dig into it.
I will be doing some additional documentation and examples for how you can access or do certain things on my YouTube channel located here: http://youtube.com/pressreset.
I will be doing a video on this script with in depth information on how to install it and get it working.
Right now, this code was developed on a Windows machine, but can easily work on a Mac with a few tweaks. I'll get to it at some point as I really do need it work on on Linux/FreeBSD.
https://github.com/pressreset/resutil
Run script with:
This is a script I started working on last night which will do various functions for Resolve.
Right now it will do the following:
This creates directory structure for a project where you store your projects based on the config.yml file .
Here is what it will do when you fileinit:
Look in the config.yml for filesystem location and project directory structures.
Make all relevant directories for a named project, so you can just go and drop your assets in.
This is the second process to run and it will build a Resolve project with the values from config.yml.
Here is what it will do when you resolveinit:
Look in the config.yml for all config variables.
Check that relevant project on filesystem exists.
Initiate a connection to Resolve's backend scripting process.
Load the Project Manager.
Create a new project based on whatever name you have supplied.
Set setting options for the project (frame rate etc)
Load the media pool.
Select all your footage inside the project's directories.
Create bins for each folder and sub folder, ingesting footage along the way.
If you have specifically told it to inside the config and you have set up a trigger folder it will:
Take all your Master Timeline/A Camera footage and assemble that onto a new timeline of your naming.
Look in config.yaml and create any additional bins that don't exist on filesystem (eg, titles etc).
Switch to whatever page tab you have selected to start your edit on.
Save the project.
Yes, I know... I'm kind of scant with documenting here also... but I will be adding to the documentation on github as it expands so that's where to look for more in depth documentation.
Here are some of the things I plan on adding that I need/want scripted:
clone - Offload footage from a card or other media to project folder and auto ingest.
export - Export a specific project #/current project.
archive - Archive a specific project #/current project.
render - Render a project # or submit it to render server in various formats.
proxy - Render proxies for project #, local or remote and organize them.
normal - Normalize all audio tracks to input gain individually.
average - Normalize all audio tracks input averaged.
buff - Normalize, place compressor and limit tracks.
abnormal - Undo normalize on all audio tracks.
delorean - Takes a project to a specific version, re-opens at that version.
docbrown - Takes a project back to earliest version you imported/started at.
marty - Takes a project back to the future... to the newest version.
biff - Doesn't actually do anything, just in the way.
mouth - Selects a project, takes timeline you select and reframes for Instagram.
chunk - Takes a project and breaks it into chunked timelines based on markers you've added.
camshow - Auto build multicam clip sequences for all your clips, make timeline.
shadow - Shadow a timeline to another project.
bumpit - Insert your bumpers/leaders/motion graphics automatically.
mumps - Same as bumpit, but only motion graphics, and all on new track.
reducio - Archive a project by #, and bundle a zip for internet transfer.
presto - Imports archive, submits render automatically then removes project from database.
changeo - Imports archive, cleans white space, dead clips, cut-throughs etc, re-archives.
correcto - Apply auto-correct to all clips on a timeline.
7of9 - Apply a specific REC709 lut to everything automatically.
ventura - Apply an ACE tranformation automatically.
crayola - Batch color your clips based on bins/metadata.
config - Change any config variable for whatever project from here.
att - Connect to a remote machine and run this script.
shazam - Run a whole batch of commands in sequence from the config file.
So,
I dug into the API. I know there are a lot of complaints about the scant documentation. It's... not so bad IMHO. Don't get me wrong, it could be a LOT better, but it's really not that bad.
This script will be expanded on as time goes on, I may even decide to do a GUI at some point.
This is what I whipped up pretty quick and there aren't a lot of checks for validity yet. Code is commented to death so that people can see what is going on, since there aren't many examples or documentation sets for Resolve.
The API has a lot in it, way more than documented...you just have to dig into it.
I will be doing some additional documentation and examples for how you can access or do certain things on my YouTube channel located here: http://youtube.com/pressreset.
I will be doing a video on this script with in depth information on how to install it and get it working.
Right now, this code was developed on a Windows machine, but can easily work on a Mac with a few tweaks. I'll get to it at some point as I really do need it work on on Linux/FreeBSD.
https://github.com/pressreset/resutil
Run script with:
- Code: Select all
resutil.py <option>
This is a script I started working on last night which will do various functions for Resolve.
Right now it will do the following:
- Code: Select all
fileinit
This creates directory structure for a project where you store your projects based on the config.yml file .
Here is what it will do when you fileinit:
Look in the config.yml for filesystem location and project directory structures.
Make all relevant directories for a named project, so you can just go and drop your assets in.
- Code: Select all
resolveinit (Resolve must be running locally or remote!)
This is the second process to run and it will build a Resolve project with the values from config.yml.
Here is what it will do when you resolveinit:
Look in the config.yml for all config variables.
Check that relevant project on filesystem exists.
Initiate a connection to Resolve's backend scripting process.
Load the Project Manager.
Create a new project based on whatever name you have supplied.
Set setting options for the project (frame rate etc)
Load the media pool.
Select all your footage inside the project's directories.
Create bins for each folder and sub folder, ingesting footage along the way.
If you have specifically told it to inside the config and you have set up a trigger folder it will:
Take all your Master Timeline/A Camera footage and assemble that onto a new timeline of your naming.
Look in config.yaml and create any additional bins that don't exist on filesystem (eg, titles etc).
Switch to whatever page tab you have selected to start your edit on.
Save the project.
Yes, I know... I'm kind of scant with documenting here also... but I will be adding to the documentation on github as it expands so that's where to look for more in depth documentation.
Here are some of the things I plan on adding that I need/want scripted:
clone - Offload footage from a card or other media to project folder and auto ingest.
export - Export a specific project #/current project.
archive - Archive a specific project #/current project.
render - Render a project # or submit it to render server in various formats.
proxy - Render proxies for project #, local or remote and organize them.
normal - Normalize all audio tracks to input gain individually.
average - Normalize all audio tracks input averaged.
buff - Normalize, place compressor and limit tracks.
abnormal - Undo normalize on all audio tracks.
delorean - Takes a project to a specific version, re-opens at that version.
docbrown - Takes a project back to earliest version you imported/started at.
marty - Takes a project back to the future... to the newest version.
biff - Doesn't actually do anything, just in the way.
mouth - Selects a project, takes timeline you select and reframes for Instagram.
chunk - Takes a project and breaks it into chunked timelines based on markers you've added.
camshow - Auto build multicam clip sequences for all your clips, make timeline.
shadow - Shadow a timeline to another project.
bumpit - Insert your bumpers/leaders/motion graphics automatically.
mumps - Same as bumpit, but only motion graphics, and all on new track.
reducio - Archive a project by #, and bundle a zip for internet transfer.
presto - Imports archive, submits render automatically then removes project from database.
changeo - Imports archive, cleans white space, dead clips, cut-throughs etc, re-archives.
correcto - Apply auto-correct to all clips on a timeline.
7of9 - Apply a specific REC709 lut to everything automatically.
ventura - Apply an ACE tranformation automatically.
crayola - Batch color your clips based on bins/metadata.
config - Change any config variable for whatever project from here.
att - Connect to a remote machine and run this script.
shazam - Run a whole batch of commands in sequence from the config file.