Old 08-13-2019, 03:07 AM   #1
Travesty
Human being with feelings
 
Travesty's Avatar
 
Join Date: Nov 2014
Posts: 798
Default Copying tracks from one project to another

I'm struggling to find a nice way to copy tracks from one project to another in lua.

I'm having to resort to native commands, and it's getting messy because the script doesn't wait for them to complete.

I can get the tracks, and select the destination project, but there doesn't seem to be any way to instantiate them in the selected project. The only track management that exists in script seems to be within a single project.

Has anyone tried anything similar?
Travesty is offline   Reply With Quote
Old 08-13-2019, 02:58 PM   #2
Meo-Ada Mespotine
Human being with feelings
 
Meo-Ada Mespotine's Avatar
 
Join Date: May 2017
Location: Leipzig
Posts: 6,621
Default

If you use my Ultraschall-API, you can use

ultraschall.GetTrackStateChunk_Tracknumber to get the StateChunk of a track. This holds all settings and attributes of a track.
https://mespotin.uber.space/Ultrasch...nk_Tracknumber

reaper.SelectProjectInstance to select another project
https://mespotin.uber.space/Ultrasch...rojectInstance

InsertTrack_TrackStateChunk to insert the TrackStateChunk into the other project
https://mespotin.uber.space/Ultrasch...rackStateChunk

This would be my approach.
__________________
Use you/she/her.Ultraschall-Api Lua Api4Reaper - Donate, if you wish

On vacation for the time being...
Meo-Ada Mespotine is offline   Reply With Quote
Old 08-21-2019, 06:56 AM   #3
Travesty
Human being with feelings
 
Travesty's Avatar
 
Join Date: Nov 2014
Posts: 798
Default

Cool, thanks, I'll try that
Travesty is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 03:09 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.