|
|
|
06-28-2020, 03:00 AM
|
#1
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Scripts for recording takes without splits
Hi guys,
I made two scripts a while back, that basically disable take auto-splitting when running in the background. Internally they work by automatically switching the recording mode to "record into lanes(layers)" and then cutting up the new layer when recording is done.
One caveat: You have to undo twice to undo your recorded take. (The first undo will bring back the recorded layer)
A: Without item extending (treat edges of items like splits)
B: With item extending
You can find the scripts on my github or download them using ReaPack:
Copy and paste this link into: Extensions > ReaPack > Import a repository
Code:
https://raw.githubusercontent.com/iliaspoulakis/Reaper-Tools/master/index.xml
Donation Link
Last edited by FeedTheCat; 07-23-2020 at 04:03 PM.
|
|
|
06-28-2020, 07:55 AM
|
#2
|
Human being with feelings
Join Date: Apr 2013
Location: France
Posts: 9,875
|
Nice !
I have made scripts to handle this problem after recoridng but not in background like that... can be very handy, thx !
note : consider reapack for sharing :P
https://reapack.com/upload
|
|
|
06-28-2020, 10:56 AM
|
#3
|
Human being with feelings
Join Date: Sep 2008
Location: Sweden
Posts: 7,416
|
Hey! This looks great!
Thanks.
__________________
// MVHMF
I never always did the right thing, but all I did wasn't wrong...
|
|
|
06-28-2020, 03:51 PM
|
#4
|
Human being with feelings
Join Date: May 2018
Location: Los Angeles
Posts: 1,719
|
NICE ONE FTC!!
Quote:
Originally Posted by X-Raym
Nice !
I have made scripts to handle this problem after recoridng but not in background like that... can be very handy, thx !
|
Yeah... me too... although I think this will be more elegant.
Will try it tomorrow.
Great job @ FTC!!
__________________
Cheers... Andrew K
Reaper v6.80+dev0621 - June 21 2023 • Catalina • Mac Mini 2020 6 core i7 • 64GB RAM • OS: Catalina • 4K monitor • RME RayDAT card with Sync Card and extended Light Pipe.
|
|
|
06-28-2020, 08:24 PM
|
#5
|
Human being with feelings
Join Date: Dec 2017
Location: Brazil
Posts: 1,992
|
Super Nice!!! Thanks
Already put in my fav scripts toolbar, will be testing it
Quote:
Originally Posted by X-Raym
|
2!
|
|
|
06-29-2020, 03:40 AM
|
#6
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Right, I'm posting again since this script got a brand new thread of its own:
I'm on W10 x64 with Reaper 6.12c, and the script is not working here. Here's what I'm doing:
1) arm track
2) set recording to split into takes (default)
3) run script
4) start recording
5) record again (shorter? longer? it doesn't matter...)
Et voilà, the takes are all split as usual. I'm attaching a gif, it hopefully shows clearly so you can help me spot what I'm doing wrong!!
Thanks again,
M
|
|
|
06-29-2020, 09:41 AM
|
#7
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Hi metronomme,
GIFs are always helpful Everything looks just fine though... I tried some stuff I had in mind to make the script malfunction, but nothing worked (which is a good thing I suppose ). So I need more info I guess. Could you check if the recording mode is switching to "Creates new media items in separate lanes (layers)" during recording? Doesn't look like it is, which pretty much would mean the script is not running in the background. Anything that's weird about your reaper setup? Stuff you have changed that come to mind or other scripts that are running?
|
|
|
06-30-2020, 01:28 AM
|
#8
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Nah, I checked and as soon as I press record, the mode changes to "lanes (layers)", as expected.
I tried the script on a fresh, portable install of Reaper 6.12 and it also doesn't work! It is clearly something I am doing wrong
A couple of things:
* Are there any obvious dependencies that I am unaware of? (other scripts that everyone normally has but I might be missing?)
* Do the two version of the script need to be running at the same time for this to work? (I am only running the "extend items" version, and the other version is not even imported).
Thanks a lot for your help, and sorry for this mess...
Another hint:
- You mentioned the script creates a "double undo step" when reversing the recording, right? Well, in my case, as soon as I finish recording, if I press "undo" the recording is gone (in one only step), meaning that the script is not working somewhere after changing the mode to "lanes"
PS: I tried to have the two scripts running at the same time but they are clearly mutually exclusive: turning one on terminates the other, so that definitely can't be the answer to my problems
Last edited by metronomme; 06-30-2020 at 01:40 AM.
|
|
|
06-30-2020, 02:24 AM
|
#9
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by metronomme
Nah, I checked and as soon as I press record, the mode changes to "lanes (layers)", as expected.
I tried the script on a fresh, portable install of Reaper 6.12 and it also doesn't work! It is clearly something I am doing wrong
|
To be fair, you seem to be doing everything correctly. What OS are you on? Maybe somebody else could also check if it works?
Quote:
Originally Posted by metronomme
A couple of things:
* Are there any obvious dependencies that I am unaware of? (other scripts that everyone normally has but I might be missing?)
* Do the two version of the script need to be running at the same time for this to work? (I am only running the "extend items" version, and the other version is not even imported).
|
* There are no dependencies
* I made the scripts mutually exclusive so they don't get in a race condition. That's where I originally thought the issue might be...
Thanks for the hints, that gives me a lot more to work with! I'll have a look in the code right now. It's a bit hard to see what's going wrong, when I can't replicate it. I'll maybe add some debugging output so you can send me a screenshot of that, if that's ok with you.
|
|
|
06-30-2020, 03:29 AM
|
#10
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
@metronomme
Ok here's a version with some enabled debugging output:
https://stash.reaper.fm/v/39817/FTC_...29%20DEBUG.lua
Could you record once over an existing take while this is running and send me a screenshot of the console output?
While looking through the code I also found a bug that would affect empty lanes (fix incoming). And I had totally forgotten that it works with multiple armed tracks, which is pretty cool:
|
|
|
06-30-2020, 07:38 AM
|
#11
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Code:
Play state changed. Current state: 0
Play state changed. Current state: 5
Switching to recording in layers
Found 1 armed track(s)
Track 2 contains 0 items before recording
Play state changed. Current state: 0
Restoring original recording mode
Track 2 contains 0 items after recording
Found 0 new item(s)!
Play state changed. Current state: 5
Switching to recording in layers
Found 1 armed track(s)
Track 2 contains 1 items before recording
Play state changed. Current state: 0
Restoring original recording mode
Track 2 contains 1 items after recording
Found 0 new item(s)!
Well, I think we might be onto something here....
Code:
"Found 0 new item(s)!"
That's clearly not what should happen, right?
(By the way, it says "Track 2 contains ..." but I did the recording test a fresh new project, which only contained 1 track!)
If I knew anything about lua scripting, I would try and delve into the code... but I don't
Thanks for your help, @FeedTheCat !
|
|
|
06-30-2020, 09:12 AM
|
#12
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by metronomme
(By the way, it says "Track 2 contains ..." but I did the recording test a fresh new project, which only contained 1 track!)
|
Yeah it should say Track 1, that's an oopsie on my part
So it doesn't find a new item after recording :S Now that's weird. Since it successfully switches into the layer recording mode... Could you test the layer recording mode without the script running? Does that create a new item in a new lane?
Also, it looks like you recorded twice. What happened during the first recording? Wasn't there a new item on the track after recording?
Code:
Track 2 contains 0 items before recording
Track 2 contains 0 items after recording
Found 0 new item(s)!
|
|
|
06-30-2020, 09:21 AM
|
#13
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
I recorded twice, indeed. The first time, to create the initial item. The second time, to create the new overlapping take.
Each time I recorded, I ended with a new item in the track however the script didn't recognise it.
|
|
|
06-30-2020, 10:49 AM
|
#14
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
I updated the debugging script. It has a potential fix and some more debugging output. I'd appreciate if you could post the console output:
https://stash.reaper.fm/v/39817/FTC_...29%20DEBUG.lua
|
|
|
06-30-2020, 01:15 PM
|
#15
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Code:
Play state changed. Current state: 0
Play state changed. Current state: 5
Switching to recording in layers
Found 1 armed track(s)
Armed track 1 contains 0 items before recording
Track GUID: {789017F2-357B-47ED-A65C-9E48D9FD9944}
userdata: 000000000358B500
Play state changed. Current state: 0
Restoring original recording mode
Armed track 1:
Track GUID: {789017F2-357B-47ED-A65C-9E48D9FD9944}
userdata: 000000000358B500
It's the same track!
Armed track 1 contains 0 items after recording
Found 0 new item(s)!
Play state changed. Current state: 5
Switching to recording in layers
Found 1 armed track(s)
Armed track 1 contains 1 items before recording
Track GUID: {789017F2-357B-47ED-A65C-9E48D9FD9944}
userdata: 000000000358B500
Play state changed. Current state: 0
Restoring original recording mode
Armed track 1:
Track GUID: {789017F2-357B-47ED-A65C-9E48D9FD9944}
userdata: 000000000358B500
It's the same track!
Armed track 1 contains 1 items after recording
Found 0 new item(s)!
I just want to say how grateful I am that you are taking all this time to take care of this!
Would it be worth me sending my reaper.ini or any of those config files so you can reproduce my system on a portable install? (I wonder if I inadvertently set an option that is preventing the script from working?)
|
|
|
06-30-2020, 02:28 PM
|
#16
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Well, there's all my suspicions out the window
Quote:
Originally Posted by metronomme
I just want to say how grateful I am that you are taking all this time to take care of this!
|
Sure mate You seem adamant about making it work so I don't mind at all.
Quote:
Originally Posted by metronomme
Would it be worth me sending my reaper.ini or any of those config files so you can reproduce my system on a portable install? (I wonder if I inadvertently set an option that is preventing the script from working?)
|
Could be worth a shot. It has to be some sort of setting. If only reaper didn't have 2 billion You said it does not work on your computer on a fresh portable install?
|
|
|
06-30-2020, 04:16 PM
|
#17
|
Human being with feelings
Join Date: Sep 2019
Posts: 42
|
Finally thank you man!Now we can use take system without pain in the ass!!
|
|
|
06-30-2020, 04:59 PM
|
#18
|
Human being with feelings
Join Date: Sep 2012
Posts: 40
|
Great!
Your script is fantastic. Even better now.
I think that works only if the script runs from the first take. The script cannot work if there are already takes with a comp (without your script running), and we want to run your script for another recording from the beginning, without any split? Or am I missing something?
|
|
|
06-30-2020, 05:22 PM
|
#19
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Quote:
Originally Posted by FeedTheCat
You said it does not work on your computer on a fresh portable install?
|
It doesn't. All the debug logs I've been sending come from the portable install...
I may try tomorrow to make a new fresh portable install and see if that changes anything, but in the meantime, here is the reaper.ini files of both the portable install, and my production install.
I am trying to get up to speed to learn ReaScript, I'd love to be able to help sorting this out! (But for the time being, I am pretty useless with both lua and eel...)
|
|
|
06-30-2020, 05:27 PM
|
#20
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Oops, the portable install's ini didn't upload. Here it is:
|
|
|
07-01-2020, 12:22 AM
|
#21
|
Human being with feelings
Join Date: Apr 2020
Posts: 1,501
|
Oh wow! This is a real improvement on the confusing take system on Reaper!
This should really be the style of takes BY default on Reaper. Now about those autosplits...
Thank you!
|
|
|
07-01-2020, 01:12 AM
|
#22
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by xav
Great!
Your script is fantastic. Even better now.
I think that works only if the script runs from the first take. The script cannot work if there are already takes with a comp (without your script running), and we want to run your script for another recording from the beginning, without any split? Or am I missing something?
|
That sounds about right. The script only extends items until it hits another existing item. Look at the following example. One might expect the first two items to be combined into one take. But that would be a destructive process in reaper, since it is currently not possible for a single take to contain multiple source files (has been requested). As it stands the items would have to be glued together, which might not be a good idea. Hope I'm making sense, just woke up
|
|
|
07-01-2020, 01:45 AM
|
#23
|
Human being with feelings
Join Date: Apr 2018
Location: Atlanta, GA, USA
Posts: 194
|
This is great. It would be nice if you could share it via Reapack too.
|
|
|
07-01-2020, 02:19 AM
|
#24
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by myfeltgood
This is great. It would be nice if you could share it via Reapack too.
|
I'll look into that over the weekend.
|
|
|
07-01-2020, 04:33 AM
|
#25
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Right!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
I found it.
(Bloooody hell....) ��*♀️��
In my setup, Reaper prompts me to keep/discard upon every recording. That means that when play_state changes to stop and the script runs the code to check for new items, the new item is still not created in the arrangement area!
I disabled that and it works like a charm.
However, I would love to keep using the "new recording prompt"; is there a way to trigger the code only when the take is actually created?
I am thinking something like this pseudo code:
Code:
var isRecordPrompt = 1
if play_state changes
if isRecordPrompt
wait until item is created / recording validated
count new items
endif
count new items
endif
I tried to look in the reascript api for a function to wait until the new record prompt is accepted, but couldn't find. Is there something like this? Otherwise I'll happily live without it; your script is definitely worth it!
Thanks
Last edited by metronomme; 07-01-2020 at 04:41 AM.
|
|
|
07-01-2020, 09:08 AM
|
#26
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
haha, that makes so much sense I had totally forgotten that existed. It's even the default behavior isn't it?
Quote:
Originally Posted by metronomme
I tried to look in the reascript api for a function to wait until the new record prompt is accepted, but couldn't find. Is there something like this? Otherwise I'll happily live without it; your script is definitely worth it!
Thanks
|
I don't think there is something that gets triggered after that dialog. But I'll see if I can find some elegant solution.
|
|
|
07-01-2020, 09:35 AM
|
#27
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
At least it would be nice if we could get the user prefs and check that the option is not checked; if it is, the script could warn the user so it can be changed manually!
Or at least, now that you know you can document it so we avoid surprises...
Thanks a lot for your hard work!
|
|
|
07-01-2020, 10:28 AM
|
#28
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by metronomme
At least it would be nice if we could get the user prefs and check that the option is not checked; if it is, the script could warn the user so it can be changed manually!
Or at least, now that you know you can document it so we avoid surprises...
Thanks a lot for your hard work!
|
I had it checked as well There's also different actions to stop recording in different ways, so I haven't seen this dialog for ages.. Anyhow, I think I found a relatively elegant solution. Could you check if it works?
https://stash.reaper.fm/v/39817/FTC_...29%20DEBUG.lua
|
|
|
07-03-2020, 10:04 AM
|
#29
|
Human being with feelings
Join Date: Sep 2012
Posts: 40
|
Once more thank you very much FeedtheCat, comping is now really easier.
Just one more question : reascript console output window pops up everytime I play or record when your script is active. Not a big deal, but is it possible to avoid that?
|
|
|
07-03-2020, 12:09 PM
|
#30
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by xav
Once more thank you very much FeedtheCat, comping is now really easier.
Just one more question : reascript console output window pops up everytime I play or record when your script is active. Not a big deal, but is it possible to avoid that?
|
I think you might be using an old DEBUG version I posted for metronomme. I'm not quite sure yet how good this version works. For now it's safer to use the one from the first post. Or even the latest DEBUG version and tell me if it works If you want to quickly disable the reascript output, there should be this line in the script somewhere near the top: "local debug = true". Change the true to false. ("local debug = false")
|
|
|
07-03-2020, 02:23 PM
|
#31
|
Human being with feelings
Join Date: Sep 2012
Posts: 40
|
Yes! It's perfect now.
|
|
|
07-10-2020, 04:21 AM
|
#32
|
Human being with feelings
Join Date: Mar 2018
Posts: 35
|
Quote:
Originally Posted by FeedTheCat
I had it checked as well There's also different actions to stop recording in different ways, so I haven't seen this dialog for ages.. Anyhow, I think I found a relatively elegant solution. Could you check if it works?
https://stash.reaper.fm/v/39817/FTC_...29%20DEBUG.lua
|
Sorry for taking so long in checking this, I have been using your script with the option "prompt to save/delete/rename new files" switched off, and it works a charm.
However, I did try today with your debug script, and it threw the following error:
Code:
...Record takes without new splits (extend items) DEBUG.lua:57: bad argument #1 to 'SetMediaItemTakeInfo_Value' (MediaItem_Take expected)
|
|
|
07-10-2020, 04:56 AM
|
#33
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Great scripts! Thank you! These behaviors should be native to Reaper. Consider sharing them via ReaPack. They will be available to more people and it will be easier for you to maintain and for people to always get the latest version etc.
|
|
|
07-10-2020, 05:28 AM
|
#34
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Quote:
Originally Posted by FeedTheCat
One caveat: You have to undo twice to undo your recorded take. (The first undo will bring back the recorded layer)
|
If you don't create undo points by yourself then when undoing you don't have to undo twice. BUT if you decide to redo after undoing then you get overlapping items and not what your script did.
|
|
|
07-10-2020, 12:49 PM
|
#35
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by amagalma
Great scripts! Thank you! These behaviors should be native to Reaper. Consider sharing them via ReaPack. They will be available to more people and it will be easier for you to maintain and for people to always get the latest version etc.
|
Yup, will do. I keep saying that lol Still really busy on my Midi Editor Magic script.
Quote:
Originally Posted by amagalma
If you don't create undo points by yourself then when undoing you don't have to undo twice. BUT if you decide to redo after undoing then you get overlapping items and not what your script did.
|
yeah... there's downsides to both. Wish we could consolidate existing undo points.
|
|
|
07-23-2020, 04:06 PM
|
#36
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Hi guys, the scripts are now available in ReaPack. I also made some improvements. The scripts should now work more reliable.
|
|
|
08-12-2020, 09:31 AM
|
#37
|
Human being with feelings
Join Date: Nov 2018
Posts: 652
|
Brilliant Script! Combined with the actions for New Recording Takes and New Recording Tape Mode so that it will toggle the script on and off.
Might be cool to integrate that into the script. Just a thought, though the combined action works well enough for those that switch between takes and tape mode.
Thanks again! All 3 of your scripts are things I've wished for for a LONG time. Keep going! (donation coming)
|
|
|
08-12-2020, 10:15 AM
|
#38
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by vsthem
Brilliant Script! Combined with the actions for New Recording Takes and New Recording Tape Mode so that it will toggle the script on and off.
Might be cool to integrate that into the script. Just a thought, though the combined action works well enough for those that switch between takes and tape mode.
Thanks again! All 3 of your scripts are things I've wished for for a LONG time. Keep going! (donation coming)
|
Thanks vsthem! That's nice to hear I didn't quite get how you combined the actions, just beware that when this script is running it essentially behaves like a 4th recording mode (1:takes, 2:tape, 3:layers).
|
|
|
08-23-2020, 04:14 PM
|
#39
|
Human being with feelings
Join Date: Jun 2011
Posts: 603
|
Hi thanks for this great script.I would like to ask one thing.
Record takes without new splits (exten item).lua
scenario 1- I push record button and begin recording, then stop button to stop recording. Script is working.
scenario 2- I push record button and begin recording then record button again to finish recording(so reaper is still playing). Script is not working.
Is there a way that scenario 2 is also possible?
|
|
|
08-24-2020, 02:14 AM
|
#40
|
Human being with feelings
Join Date: May 2019
Location: Berlin
Posts: 2,163
|
Quote:
Originally Posted by mehmethan
Hi thanks for this great script.I would like to ask one thing.
Record takes without new splits (exten item).lua
scenario 1- I push record button and begin recording, then stop button to stop recording. Script is working.
scenario 2- I push record button and begin recording then record button again to finish recording(so reaper is still playing). Script is not working.
Is there a way that scenario 2 is also possible?
|
Sure, should be fixed now
|
|
|
Thread Tools |
|
Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -7. The time now is 06:54 AM.
|