Creating Scripts for DaVinci Resolve

Get answers to your questions about color grading, editing and finishing with DaVinci Resolve.
  • Author
  • Message
Offline
User avatar

Igor Riđanović

  • Posts: 1547
  • Joined: Thu Jul 02, 2015 5:11 am
  • Location: Los Angeles, Calif.

Re: Creating Scripts for DaVinci Resolve

PostFri Apr 21, 2023 7:16 pm

I'm trying to remember how that worked. Did it move only the media associated with a timeline or a project? Did it relink to the media at the new location? I think both those are possible to achieve, although I'd have to test the relinking. I'm not sure that I ever attempted that.

Would Resolve Collect not work for you: https://www.niwa.nu/resolve-collect/
www.metafide.com - DaVinci Resolve™ Apps
Offline

jjsereday

  • Posts: 38
  • Joined: Thu May 26, 2022 8:58 am
  • Real Name: JJ Sereday

Re: Copy Timeline Clip Markers to Media Pool

PostMon Apr 24, 2023 1:44 am

Wow incredible to see this thread. Really hoping to see more functionality with the API!

I've been racking my brain trying to find/figure out how to convert used clips in a timeline into marker durations within the media pool.

its easy 2 step process manually but with hundreds of clips in a timeline, a script to do so would be life changing...
Offline

dahya.mistry

  • Posts: 60
  • Joined: Wed Mar 03, 2021 5:29 pm
  • Real Name: Dahya Mistry

Re: Creating Scripts for DaVinci Resolve

PostMon Apr 24, 2023 10:33 am

FYI in case people don't spot it:

Forum Suggestion: Add a DR Scripts Forum
https://forum.blackmagicdesign.com/viewtopic.php?f=21&t=180039
Offline
User avatar

roger.magnusson

  • Posts: 3248
  • Joined: Wed Sep 23, 2015 4:58 pm

Timeline Clips to Media Pool Duration Markers

PostMon Apr 24, 2023 11:06 am

A bit too much on my plate right now to make it a fully finished script. But this might get you started at least.

Code: Select all
local project = resolve:GetProjectManager():GetCurrentProject()
local timeline = project:GetCurrentTimeline()
local marker_colors = table.pack("Blue", "Cyan", "Green", "Yellow", "Red", "Pink", "Purple", "Fuchsia", "Rose", "Lavender", "Sky", "Mint", "Lemon", "Sand", "Cocoa", "Cream")

for track_index = 1, timeline:GetTrackCount("video") do
   local track_name = timeline:GetTrackName("video", track_index)

   for _, timeline_item in ipairs(timeline:GetItemListInTrack("video", track_index)) do
      local media_pool_item = timeline_item:GetMediaPoolItem()
      media_pool_item:AddMarker(timeline_item:GetLeftOffset(), marker_colors[(track_index - 1) % #marker_colors + 1], "Track: "..track_name, "", timeline_item:GetDuration())
   end
end


It's "dumb" in the sense that it doesn't clear existing media pool item markers, doesn't check if the same in point is used more than once (which will make it ignore that timeline clip) and it only looks at video, not audio.

One thing to note is that the visual out point of a marker isn't inclusive of the frame duration. So it will look like it's one frame short even though the numbers are correct. If you want to change it for some reason, just replace timeline_item:GetDuration() with timeline_item:GetDuration() + 1.
Offline

jjsereday

  • Posts: 38
  • Joined: Thu May 26, 2022 8:58 am
  • Real Name: JJ Sereday

Re: Creating Scripts for DaVinci Resolve

PostThu Apr 27, 2023 3:47 pm

Wow Roger thanks for this - even in it's raw form it works for my needs.

I tweaked it to also add markers for tracks 2 and so on, which is a great way to add specific labels to all the clips selected.

When pulling usable selects I keep them on track one and label the track "Selects" and move favorites to track 2 and label the track "Selects Favorites"

and after running the script the duration markers are applied with those titles :o

I feel like this has so much more potential for choosing marker colors and even labeling which timeline media is used until Blackmagic gives us that feature.
Offline

robgwilson

  • Posts: 6
  • Joined: Thu Mar 26, 2015 2:26 am

Re: Creating Scripts for DaVinci Resolve

PostThu Apr 27, 2023 6:27 pm

You know what script would be super helpful? If you could extract the Date Created metadata from the file and generate timecode off that for a file. I've got a camera card I just inherited that ran continuous timecode but I'm trying to make it TOD. Even if I could get it close, I could sync from there. Right now it's just a mess.
Offline

Uli Plank

  • Posts: 19689
  • Joined: Fri Feb 08, 2013 2:48 am
  • Location: Germany and Indonesia

Re: Creating Scripts for DaVinci Resolve

PostFri Apr 28, 2023 12:26 am

Can't offer such a script, but there's external software offering just that, like EditReady.
DaVinci Resolve is very capable even for free, but you need the right hardware!

Studio 18.6.3, MacOS 12.7.1
MacBook M1 Pro, 16 GPU cores, 32 GB RAM and iPhone 15 Pro
Speed Editor, UltraStudio Monitor 3G, iMac 2017
Offline
User avatar

roger.magnusson

  • Posts: 3248
  • Joined: Wed Sep 23, 2015 4:58 pm

Re: Creating Scripts for DaVinci Resolve

PostFri Apr 28, 2023 12:52 pm

That's an easy change for the "Set Timecode for Media Pool Clips" script. I have added a checkbox that lets you create timecode from the "Date Created" metadata field instead.

Image
Post: Set Timecode for Media Pool Clips [Download]
Offline
User avatar

iddos-l

  • Posts: 798
  • Joined: Sat Mar 30, 2019 7:55 pm
  • Real Name: iddo lahman

Re: Creating Scripts for DaVinci Resolve

PostThu May 18, 2023 2:25 pm

Can anyone confirm there is no method to get or set the TimelineItem speed? I'm trying to find all clips in a timeline that have a speed change but can't find any method in the API.
Offline
User avatar

Igor Riđanović

  • Posts: 1547
  • Joined: Thu Jul 02, 2015 5:11 am
  • Location: Los Angeles, Calif.

Re: Creating Scripts for DaVinci Resolve

PostFri May 19, 2023 5:46 pm

Last time I needed that maybe three years ago there wasn't one. I don't recall seeing it added. I think you can get enough information to calculate it yourself, but you can't calculate if there are keyframed speed ramps.
www.metafide.com - DaVinci Resolve™ Apps
Offline
User avatar

roger.magnusson

  • Posts: 3248
  • Joined: Wed Sep 23, 2015 4:58 pm

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 10:22 am

If you export the timeline to an OpenTimelineIO file (a JSON file) in 18.5 Beta 3 or later, you can get both the clip speed and keyframes.

Code: Select all
local project = resolve:GetProjectManager():GetCurrentProject()
local timeline = project:GetCurrentTimeline()
timeline:Export([[D:\Temp\timeline.otio]], resolve.EXPORT_OTIO)
Offline
User avatar

Robert Niessner

  • Posts: 4820
  • Joined: Thu Feb 21, 2013 9:51 am
  • Location: Graz, Austria

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 10:56 am

Resolve 18.5 Beta 2 has added those improvements to the scripting API:

• Scripting API support to create subtitles from timeline audio.
• Scripting API support to transcribe source clips.

Resolve 18.5 Beta 3 has added another few improvements to the scripting API:

• Scripting API support to trigger object mask tracking.
• Scripting API support to trigger stabilization.
• Scripting API support to invoke scene cut detection in timelines.
• Scripting API support to enable smart reframe for clips.
• Scripting API support to export current frame as still.
• Scripting API for adding subclips to the media pool.
• Scripting API support to export and import OpenTimelineIO files.
• Scripting API support to render PNG and JPEG image sequences.
Last edited by Robert Niessner on Tue May 23, 2023 1:27 pm, edited 1 time in total.
Saying "Thx for help!" is not a crime.
--------------------------------
Robert Niessner
LAUFBILDkommission
Graz / Austria
--------------------------------
Blackmagic Camera Blog (German):
http://laufbildkommission.wordpress.com

Read the blog in English via Google Translate:
http://tinyurl.com/pjf6a3m
Offline
User avatar

roger.magnusson

  • Posts: 3248
  • Joined: Wed Sep 23, 2015 4:58 pm

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 11:15 am

Isn't it strange to have a Stabilize() function that doesn't allow you to set any of the stabilization parameters? I wonder what the use case is here.

They've added some useful functions to Timeline Items, but there's no way through the API to find out which items are selected on the timeline. So how would it be used?
Offline
User avatar

Robert Niessner

  • Posts: 4820
  • Joined: Thu Feb 21, 2013 9:51 am
  • Location: Graz, Austria

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 11:33 am

roger.magnusson wrote:Isn't it strange to have a Stabilize() function that doesn't allow you to set any of the stabilization parameters? I wonder what the use case is here.


My guess is this is just a result of the new ability to do batch stabilization of selected clips. Hopefully this gets improved with parameter settings.
Saying "Thx for help!" is not a crime.
--------------------------------
Robert Niessner
LAUFBILDkommission
Graz / Austria
--------------------------------
Blackmagic Camera Blog (German):
http://laufbildkommission.wordpress.com

Read the blog in English via Google Translate:
http://tinyurl.com/pjf6a3m
Offline
User avatar

iddos-l

  • Posts: 798
  • Joined: Sat Mar 30, 2019 7:55 pm
  • Real Name: iddo lahman

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 12:07 pm

roger.magnusson wrote:If you export the timeline to an OpenTimelineIO file (a JSON file) in 18.5 Beta 3 or later, you can get both the clip speed and keyframes.

Code: Select all
local project = resolve:GetProjectManager():GetCurrentProject()
local timeline = project:GetCurrentTimeline()
timeline:Export([[D:\Temp\timeline.otio]], resolve.EXPORT_OTIO)
Nice!
Thank you
Offline
User avatar

iddos-l

  • Posts: 798
  • Joined: Sat Mar 30, 2019 7:55 pm
  • Real Name: iddo lahman

Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 12:08 pm

roger.magnusson wrote:They've added some useful functions to Timeline Items, but there's no way through the API to find out which items are selected on the timeline. So how would it be used?
I guess you can setup markers to flag the clips and then set the playhead to the timecode and get the timeline items that way.
Offline

GarryFrey

  • Posts: 2
  • Joined: Tue May 23, 2023 8:51 pm
  • Real Name: Garry Frey

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 9:12 pm

Is there a program that supports regular expressions for writing code quickly?
Offline
User avatar

Igor Riđanović

  • Posts: 1547
  • Joined: Thu Jul 02, 2015 5:11 am
  • Location: Los Angeles, Calif.

Re: Creating Scripts for DaVinci Resolve

PostTue May 23, 2023 10:01 pm

roger.magnusson wrote:If you export the timeline to an OpenTimelineIO file (a JSON file) in 18.5 Beta 3 or later, you can get both the clip speed and keyframes.

Code: Select all
local project = resolve:GetProjectManager():GetCurrentProject()
local timeline = project:GetCurrentTimeline()
timeline:Export([[D:\Temp\timeline.otio]], resolve.EXPORT_OTIO)


That's a pretty decent workaround.
www.metafide.com - DaVinci Resolve™ Apps
Offline

Lucius Snow

  • Posts: 591
  • Joined: Sun Nov 24, 2013 1:19 pm

Re: Creating Scripts for DaVinci Resolve

PostWed May 24, 2023 5:00 pm

Scripting API support to render PNG

I wish this for so long! Anyone would develop the script?
Offline

Steve Swisz

  • Posts: 65
  • Joined: Tue Aug 11, 2015 1:51 am

Re: Creating Scripts for DaVinci Resolve

PostTue May 30, 2023 8:04 pm

Igor Riđanović wrote:I'm trying to remember how that worked. Did it move only the media associated with a timeline or a project? Did it relink to the media at the new location? I think both those are possible to achieve, although I'd have to test the relinking. I'm not sure that I ever attempted that.

Would Resolve Collect not work for you: https://www.niwa.nu/resolve-collect/



Thanks Igor I am going to play around with this!
Offline

4EvrYng

  • Posts: 488
  • Joined: Sat Feb 19, 2022 12:45 am
  • Real Name: Alexander Dali

Re: Creating Scripts for DaVinci Resolve

PostWed May 31, 2023 12:15 am

roger.magnusson wrote:Scripting is a great feature in DaVinci Resolve. With the exception of a few brave souls that have shared their scripts the forum isn't exactly overflowing with them so I thought I'd make a few contributions on the subject.

Thank you!!!
Offline

Dani Urdiales

  • Posts: 18
  • Joined: Mon Jan 13, 2020 6:57 pm
  • Real Name: Dani Urdiales

Re: Creating Scripts for DaVinci Resolve

PostThu Jun 01, 2023 8:48 pm

roger.magnusson wrote:Isn't it strange to have a Stabilize() function that doesn't allow you to set any of the stabilization parameters? I wonder what the use case is here.

They've added some useful functions to Timeline Items, but there's no way through the API to find out which items are selected on the timeline. So how would it be used?
Drx can save specific stabilizer parameters if i remember correctly.
So we could apply a dummy drx with the preferred parameters.

Enviado desde mi Mi 9 Lite mediante Tapatalk
Offline
User avatar

Robert Niessner

  • Posts: 4820
  • Joined: Thu Feb 21, 2013 9:51 am
  • Location: Graz, Austria

Re: Creating Scripts for DaVinci Resolve

PostThu Jun 15, 2023 11:19 am

Resolve 18.5 Beta 4 has added those improvements to the scripting API:

• Support to add, delete, enable and lock timeline tracks.
• Support to delete and link timeline clips.
• Support to specify target track and record frame to add clips to timeline.
• Support to specify record frame to create timeline from media pool clips.
Saying "Thx for help!" is not a crime.
--------------------------------
Robert Niessner
LAUFBILDkommission
Graz / Austria
--------------------------------
Blackmagic Camera Blog (German):
http://laufbildkommission.wordpress.com

Read the blog in English via Google Translate:
http://tinyurl.com/pjf6a3m
Offline
User avatar

roger.magnusson

  • Posts: 3248
  • Joined: Wed Sep 23, 2015 4:58 pm

Re: Creating Scripts for DaVinci Resolve

PostThu Jun 15, 2023 11:28 am

Those were available even before 18.5 but undocumented. They were removed in Beta 3. Thankfully they are now officially available and documented.
Offline
User avatar

Robert Niessner

  • Posts: 4820
  • Joined: Thu Feb 21, 2013 9:51 am
  • Location: Graz, Austria

Re: Creating Scripts for DaVinci Resolve

PostThu Jun 22, 2023 9:46 am

I got an idea for a hopefully useful script for many users:

The problem:
I have created lower third templates for different purposes, with two text+ inputs for "name" and "function". That works great, no problem.
But I have to fill in the inputs over and over again when having the same people in different projects.

It would be cool to have a script which reads from a text file all names and functions and let me select from a list for semi-auto fill in the lower thirds.

The text file could e.g. consist of something like this:

[groupname]
<first name> <last name>, <function>;
<first name> <last name>, <function>;
.
.
.
<first name> <last name>, <function>;
[/groupname]

Then if the lower third comp is selected start the script and get a drop down list with all groups to select one from and then the list of names (sorted by last name). If selected a name and hit enter you get the lower third's inputs populated.

It'd be cool if entering a character a-z (and special characters like umlaut or what ever other languages have) selection would jump in the list to that last name beginning with that character.

And make a checkbox for the name fill in order: <first name> <last name> or <last name> <first name>
Maybe another checkbox to make <last name> all caps optionally.

I have seen there is some groundwork already there in this thread:
https://www.steakunderwater.com/wesuckl ... 208#p12208

I have no idea if this would be a lot of coding work or if this could be done quite fast (for myself would need a long time because I would have to start learning scripting first again).

Looking forward what others think about this. Maybe this already exists, but I haven't found anything like that so far, but I can't be the only one wanting something like this to improve working with lower thirds and minimizing typing errors and such.
Saying "Thx for help!" is not a crime.
--------------------------------
Robert Niessner
LAUFBILDkommission
Graz / Austria
--------------------------------
Blackmagic Camera Blog (German):
http://laufbildkommission.wordpress.com

Read the blog in English via Google Translate:
http://tinyurl.com/pjf6a3m
Offline

alexfry

  • Posts: 7
  • Joined: Tue Apr 17, 2018 6:03 am
  • Real Name: Alex Fry

Re: Creating Scripts for DaVinci Resolve

PostFri Jul 28, 2023 1:01 am

@roger.magnusson

Do you (or anyone else here) have any working examples of basic UI windows and widgets being instatiated from python? (rather than lua)
Offline
User avatar

Robert Niessner

  • Posts: 4820
  • Joined: Thu Feb 21, 2013 9:51 am
  • Location: Graz, Austria

Re: Creating Scripts for DaVinci Resolve

PostThu Sep 14, 2023 6:49 pm

Resolve 18.6 has added those improvements to the scripting API:

• Scripting API support to import and export render and data burn presets.
• Scripting API support to import stills and list powergrades.
• Scripting API support for per-timeline Resolve Color Management.
Saying "Thx for help!" is not a crime.
--------------------------------
Robert Niessner
LAUFBILDkommission
Graz / Austria
--------------------------------
Blackmagic Camera Blog (German):
http://laufbildkommission.wordpress.com

Read the blog in English via Google Translate:
http://tinyurl.com/pjf6a3m
Offline
User avatar

Andrew Hazelden

  • Posts: 510
  • Joined: Sat Dec 06, 2014 12:10 pm
  • Location: West Dover, Nova Scotia, Canada

Re: Creating Scripts for DaVinci Resolve

PostFri Sep 15, 2023 2:28 am

alexfry wrote:Do you (or anyone else here) have any working examples of basic UI windows and widgets being instatiated from python?


Here is a collection of Python-based UI Manager GUI creation examples. It comes from the Reactor package manager's "UI Manager Examples" atom package.
MacBook Air M1 / Threadripper 3990X | Fusion Studio 18.6 | Kartaverse 6
Offline

im_gldn

  • Posts: 16
  • Joined: Wed May 19, 2021 5:56 am
  • Real Name: Lionel Golden

Re: Creating Scripts for DaVinci Resolve

PostMon Sep 18, 2023 4:49 am

Im amazed at how much work is being done here. Im not a programmer so ill ask for help here.

Since DR now has API support for creating sutbtitles from timeline audio. Is it possible to create a script the makes longer blocks of text. So instead of creating 60 characters per line max, to being able to put together a timed amount (say 5 minutes) of subtitles in one block.

My use case is this. I have a 8x 2 hour interviews that was subtitled. I converted the subtitle.SRT to Timeline Index and import back into resolve just so i can search using the INDEX. However the Timeline markers brings in about 2500 markers on average. Which immediatley bogs the system down making it unusable.

Possible solutions:
1. Create longer subtitle blocks that capture more text.
2. Have the ability to search subtitles (as is in DR) to filter and list by search, while still being able to move to timecoded area.

Thanks for the assitance in advance.
Offline

Andy Mees

  • Posts: 3060
  • Joined: Wed Aug 22, 2012 7:48 am

Re: Creating Scripts for DaVinci Resolve

PostWed Sep 20, 2023 9:08 pm

As BMD doesn't yet provide a built-in method to find / filter subtitle track contents...

Screenshot 2023-09-26 113951.jpg
Screenshot 2023-09-26 113951.jpg (31.94 KiB) Viewed 1125 times

Andy's Subvigator is a helper that displays the active timeline's subtitles (from a chosen subtitle track) together with a case-insensitve text filter for searching those subtitles. Selecting any subtitle/block in the Subvigator window moves the timeline playhead to the start of the corresponding subtitle/block (for editing the source in the timeline). Search options are Contains, Exact, Starts With, Ends With and Wildcard (using asterisks). Enabling the 'Dynamic search text' option will update the search results as you type... great if you don't have too many subtitles to filter, otherwise just press <Enter> or <Return> to trigger the search. The 'Combine Subs' option groups and navigates subtitles as blocks, the number of subtitles per block being the number you choose... useful when working with massive subtitle lists (it acts like a speed multiplier!) but note that, when used, navigational accuracy is effectively reduced by the same factor. If working in a Drop Frame timeline, enable the the 'DF navigation' option (functionality courtesy of Roger Magnusson's Libavutil code posted earlier in this thread).
Finally, the manual 'Refresh' button rebuilds the list to reflect any changes in the timeline.

[Save to your Scripts or Workflow Integration folder]

For the adventurous, apart from cleaning up and optimising my lazy code, this basic helper could be updated to support: editing the displayed subtitles, adding a 'find and replace' function, adding spellcheck functionality and whatever else you might want to have a go at, then sending those changes back to the project via SRT).

Hope its useful
Cheers
Andy
Last edited by Andy Mees on Tue Sep 26, 2023 11:10 am, edited 2 times in total.
Offline

im_gldn

  • Posts: 16
  • Joined: Wed May 19, 2021 5:56 am
  • Real Name: Lionel Golden

Re: Creating Scripts for DaVinci Resolve

PostThu Sep 21, 2023 1:18 pm

Andy Mees wrote:Here's a (Lua driven) helper to search & navigate subtitles:

Screenshot 2023-09-20 220617.jpg

BMD doesn't yet provide a built-in method to find / filter subtitle track contents... this helper displays subtitles as a static list in a separate window and adds that missing text search capability. Clicking any row move's the timeline playhead to the selected subtitle (for editing the source in the timeline). The manual 'Refresh' button rebuilds the list to reflect any changes.

[Save to your Scripts or Workflow Integration folder]

For the adventurous, apart from cleaning up and optimising my lazy code, this basic helper could be updated to support: editing the displayed subtitles, adding a 'find and replace' function, adding spellcheck functionality and whatever else you might want to have a go at, then sending those changes back to the project via SRT).

Fair warning: I've only used this on 25p projects.... the timecode conversion routine will need help to work accurately on fractional timebases.

Hope its useful
Cheers
Andy


***edit***


Thanks for offering this Andy. It works as it should. I wished it worked more efficiently in the workflow. But im sure someone will find this useful.

Thanks again. I appreciate the work you guys do here. Picked up a couple aswesome scripts here. If i wanted to learn to create stuff like this where could find some resources.

Thanks Golden
Offline

Andy Mees

  • Posts: 3060
  • Joined: Wed Aug 22, 2012 7:48 am

Re: Creating Scripts for DaVinci Resolve

PostThu Sep 21, 2023 2:16 pm

im_gldn wrote:It works as it should
Cool.
FYI, I just updated the script to add a 'Use dynamic filter' checkbox control to the UI (default status: off) When working with large numbers of subtitles, having dynamic filtering turned off helps responsiveness dramatically... instead of triggering the filter to rebuild itself after every keypress, it waits for you enter all search text first, then manually trigger the filter by pressing <Enter> or <Return>.

im_gldn wrote:If i wanted to learn to create stuff like this where could find some resources.
If you go to Resolve's Help menu > Documentation > Developer it will take you to the Support / Developer folder in your Resolve install which contains many scripting and workflow integration code samples. Especially, check the 'ReadMe' file in the Scripting folder. If that whets your appetite, you should join the WeSuckLess forum where there's a world of super helpful people with lots of relevant code that' s freely shared.
Offline

Videoneth

  • Posts: 1476
  • Joined: Fri Nov 13, 2020 11:03 pm
  • Real Name: Maxwell Allington

Re: Creating Scripts for DaVinci Resolve

PostSun Sep 24, 2023 7:12 pm

Just installed Andy's script
Thanks to you and Roger
Windows 10
18.6.3
nVidia 3090 - 537.42
Offline

im_gldn

  • Posts: 16
  • Joined: Wed May 19, 2021 5:56 am
  • Real Name: Lionel Golden

Re: Creating Scripts for DaVinci Resolve

PostSun Sep 24, 2023 7:50 pm

Thanks Andy. I'll give it another shot.
Offline

im_gldn

  • Posts: 16
  • Joined: Wed May 19, 2021 5:56 am
  • Real Name: Lionel Golden

Re: Creating Scripts for DaVinci Resolve

PostMon Sep 25, 2023 5:15 am

UPDATE.

Rafael at editingtools.io made some changes to merge subtitles.

1. Create subtitles from Audio in Davinci Resolve. Filetype:SRT
Rafael at editingtools.io made it possible to set a time in seconds to merge subtitles.
2. Go to https://editingtools.io/subtitles/ and convert the SRT file to 15 seconds merged SRT. Remember to click "remove tags".
3. Go to https://editingtools.io/marker and convert Merged SRT to Timeline Markers. Check the "Swap marker name..." Filetype: EDL
4. Select Timeline in the BIN in DR, right click and import Timeline Markers.
i. If you are using (Andy's Subvigator) to subtitle search import merged subtitle and add to timeline.
ii. use Andy's Subvigator to search subtitles with "Use dynamic..." UNCHECKED.
5. You can use the index in DR to navigate by search.

Performance should be better since the number of indexes are reducded, based on the seconds selected to merge in Step 2.

Andy thanks again for the script & Rafael at editingtools.io


**ORIGINAL POST**
Just wanted to leave some feedback for reference.

Thanks for the update on the script it has definitely increased productivity.

The following is the workaround. It involves a bit of round-tripping.

(Create Subtitle)
1. Create subtitles from Audio in Davinci Resolve. Filetype:SRT
(Reduce the amount of Subtitles make longer text blocks. My project was reduced from 2500 to 498 subtitles)
2. Go to https://editingtools.io/marker/ and convert subtitles to Timeline Markers. Check the "Swap marker name..." and "Merge marker 10 seconds" This step removes tags and reduces the amount of subtitle lines generated for the timeline markers. Filetype: EDL
(Only way to have converted subtitles that'll keep text and timecode location)
3. Select Timeline in the BIN in DR, right click and import Timeline Markers.
4. Right click on Timeline again and export Timeline Markers. Filetype:EDL
5. Go back to editingtools.io and convert EDL to SRT
6. Import SRT into DR and drag to timeline.
7. Use Andy's Subvigator to search subtitles with "Use dynamic..." UNCHECKED.

Andy thanks again for the script & Rafael at editingtools.io
Offline

Raphael_D

  • Posts: 6
  • Joined: Tue May 12, 2020 8:26 am
  • Real Name: Raphaël Dubach

Re: Creating Scripts for DaVinci Resolve

PostTue Oct 24, 2023 1:43 pm

Hi Folks,

I'm an On/Near Set DIT working on TV show and feature with SilverStack Lab, LiveGrade, Avid Media Composer, Davinci Resolve, Base Light an many more.

Fist I wanted to thank Roger Magnusson for the Timeline Clips Batch Timecode Script, wich realy realy rocks in peculiars workflows where you need to batch offset TC from already imported Audio File inside Resolve MediaPool before Sync.
For now Resolve "Import with offset" doesn't work for audio files, only video clips. And Roger you made it possible since 2015!

As I have realy poor knowlege of Python and Lua, I wonder if there is an easy way to implement another option in the "mode" dropdown menuof the script. An option called "Audio Offset" that would add, substract or even set the existing clip audio Offset column (for now you can only do it by hand and clip per clip)
That way the TC would not be touch but you'll still get the offset correction directly on the synced clips. Modifed TC could be a great deal when exporting clips for Post-Production houses that would have trouble to correctly relink the clip to the original one if the Resolve TC is changed on Proxy or other exported files.

If you guide me maybe I would be able to add that change in the existing script.

Thank again
Offline

cat99_0

  • Posts: 13
  • Joined: Sun Feb 12, 2023 6:25 pm
  • Real Name: Danniel Ni

Re: Creating Scripts for DaVinci Resolve

PostSat Nov 04, 2023 3:01 am

Genius!!! Thank you so much for the really useful script!!
Offline

cat99_0

  • Posts: 13
  • Joined: Sun Feb 12, 2023 6:25 pm
  • Real Name: Danniel Ni

Re: Creating Scripts for DaVinci Resolve

PostSat Nov 04, 2023 9:00 am

I tested "Grab Stills at Markers.lua" on mac in18.6. It does not work now.
截屏2023-11-04 16.53.34.png
截屏2023-11-04 16.53.34.png (70.56 KiB) Viewed 460 times
Previous

Return to DaVinci Resolve

Who is online

Users browsing this forum: Bing [Bot], Boosuf, hbenthow, lucvrhovnik, Nick2021, Niclas_Lindergard, pablomdb and 299 guests