Importing XML or AAF via scripting API in Resolve

User avatar
ConorBowes
Posts: 2
Joined: Mon Jan 07, 2019 3:41 pm

Importing XML or AAF via scripting API in Resolve

#1

Post by ConorBowes » Mon Jan 07, 2019 3:43 pm

Hey all,

Just wondering if anyone has found a way to import an XML or AAF via the scripting API? I have attempted to do it via the ImportTimelineFromFile option, but I am not getting anything created when I run that command with an xml as the argument. Any guidance would be greatly appreciated.

User avatar
NickBell
Posts: 1
Joined: Sat May 25, 2019 1:29 pm

Re: Importing XML or AAF via scripting API in Resolve

#2

Post by NickBell » Thu Sep 12, 2019 1:48 pm

Hey Conor! Sorry this is 10 months old but I'm also curious if anyone has had success with XMLs/EDLs or importing many timelines programatically.


Code: Select all

resolve = Resolve()
projectManager = resolve:GetProjectManager()
project = projectManager:GetCurrentProject()
mediapool = project:GetMediaPool()
    mediapool:ImportTimelineFromFile(path) --path to timeline file

I got my resolve to import FCPXMLs via the scripting api. XMLs/AAFs/EDLs all don't throw errors in the console for me, but don't create new timelines.

Also strange and maybe someone else knows this; I can import 1 FCPXML at a time programatically, but if I try to iterate a table of paths and import each path, Resolve typically crashes for me? Or if it doesn't crash, it imports only the first FCPXML and ignores the rest. What's the deal with that?

Code: Select all

for bevers,alana in ipairs(xmlFolder) do
mediapool:ImportTimelineFromFile(alana)

end

keep in mind this is like halfway thru the script