Old 02-22-2021, 09:55 AM   #2401
Pink Wool
Human being with feelings
 
Pink Wool's Avatar
 
Join Date: Apr 2020
Posts: 1,524
Default

Quote:
Originally Posted by MusoBob View Post
You can look for a selected track and insert it the FX in it or this is out of another script to insert new track and add FX.
Code:
      commandID1 = reaper.NamedCommandLookup("_XENAKIOS_INSNEWTRACKTOP") -- Xenakios/SWS: Insert new track at the top of track list
      reaper.Main_OnCommand(commandID1, 0) -- Xenakios/SWS: Insert new track at the top of track list
      
      seltrack = reaper.GetTrack( 0, 0 )
      
      reaper.SetTrackSelected( seltrack, 1 )
      
      seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
      
      reaper.TrackFX_AddByName( seltrack, "ReaTrak note-counter.jsfx", 0, -1 )
I'm afraid I don't know how to combine this with "look for selected track" as you put it? Help?
Pink Wool is online now   Reply With Quote
Old 02-22-2021, 03:11 PM   #2402
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Try this:
Code:
 track_count = reaper.CountTracks(0)
 
 if track_count > 0 then
   seltrack = reaper.GetSelectedTrack(0,0)
   
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
   
   if not seltrack then
     reaper.MB( "Select Track", "Track ?", 0 )
     goto finish
   end
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
   
 else
 
   reaper.Main_OnCommand(40001, 0) -- Track: Insert new track
         
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
         
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
 end   
 
 ::finish::
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 02-22-2021, 11:31 PM   #2403
Pink Wool
Human being with feelings
 
Pink Wool's Avatar
 
Join Date: Apr 2020
Posts: 1,524
Default

Quote:
Originally Posted by MusoBob View Post
Try this:
Code:
 track_count = reaper.CountTracks(0)
 
 if track_count > 0 then
   seltrack = reaper.GetSelectedTrack(0,0)
   
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
   
   if not seltrack then
     reaper.MB( "Select Track", "Track ?", 0 )
     goto finish
   end
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
   
 else
 
   reaper.Main_OnCommand(40001, 0) -- Track: Insert new track
         
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
         
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
 end   
 
 ::finish::

Hey! Thanks! It seems the add new track function works only the first time though. Is there a way that it wouldn't be dependent on the track count? So that it would ALWAYS (when used) add a new track and put the fx on it, if no track was selected?
Pink Wool is online now   Reply With Quote
Old 02-23-2021, 12:27 AM   #2404
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Code:
 seltrack = reaper.GetSelectedTrack(0,0)
 
 if seltrack then
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
   
 else
 
   reaper.Main_OnCommand(40001, 0) -- Track: Insert new track
         
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
         
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
 end
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 02-23-2021, 08:22 AM   #2405
Pink Wool
Human being with feelings
 
Pink Wool's Avatar
 
Join Date: Apr 2020
Posts: 1,524
Default

Quote:
Originally Posted by MusoBob View Post
Code:
 seltrack = reaper.GetSelectedTrack(0,0)
 
 if seltrack then
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
   
 else
 
   reaper.Main_OnCommand(40001, 0) -- Track: Insert new track
         
   seltrack = reaper.GetSelectedTrack2( 0, 0, 1 )
         
   reaper.TrackFX_AddByName( seltrack, "audio_statistics", 0, -1 )
 end
Hey! It works! Thank you very much!
Pink Wool is online now   Reply With Quote
Old 02-26-2021, 07:11 PM   #2406
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Edgemeal View Post
Monitor FX uses a different indexing # for FX slot,
Try this script on toolbar button,

Getting back to this script, I managed to make it work for the master track ny change the 0x1000000 to 0x000000, but then I wanted it to work with my pre-Master bus track (which is track 1) as well but I could not figure out how to do it. I know there other ways but this script worked so well with Master and Monitor fx when it comes to have visible active toolbar buttons... so I hope it's only an easy modification that is needed...if doable


Code:
-- Toggle FX # bypass for Monitor FX
-- Edgemeal - Apr 04, 2020
-- Donate: https://www.paypal.me/Edgemeal

-- Copy this script file and rename the FX # for,
-- the FX slot number you want to toggle bypass.
-- For example,
-- Toggle FX 3 bypass for Monitor FX.lua
-- Toggle FX 4 bypass for Monitor FX.lua
-- Toggle FX 5 bypass for Monitor FX.lua
-- etc, etc...

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local track = reaper.GetMasterTrack()
local cnt = reaper.TrackFX_GetRecCount(track)
if fxIndex <= cnt then
  fxIndex = (0x1000000 + (fxIndex-1))
  local enabled = reaper.TrackFX_GetEnabled(track, fxIndex)
  reaper.TrackFX_SetEnabled(track, fxIndex, not enabled)
  -- set toolbar highlight
  local self = ({reaper.get_action_context()})[4]
  if enabled then  
    reaper.SetToggleCommandState(0, self, 1)
  else
    reaper.SetToggleCommandState(0, self, 0)
  end
end
reaper.defer(function () end)
Kr3eM is offline   Reply With Quote
Old 02-26-2021, 08:36 PM   #2407
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by Kr3eM View Post
Getting back to this script, I managed to make it work for the master track ny change the 0x1000000 to 0x000000, but then I wanted it to work with my pre-Master bus track (which is track 1) as well but I could not figure out how to do it. I know there other ways but this script worked so well with Master and Monitor fx when it comes to have visible active toolbar buttons... so I hope it's only an easy modification that is needed...if doable
Try,....
Code:
-- Toggle FX # bypass for track #
--
-- File name examples,...
-- Toggle FX 3 bypass for track 1.lua
-- Toggle FX 2 bypass for track 2.lua
-- Toggle FX 1 bypass for track 3.lua

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local trNum = tonumber(name:match("track (%d+)"))
local track = reaper.GetTrack(0,trNum-1)

if track ~= nil then
  local cnt = reaper.TrackFX_GetCount(track) 
  if fxIndex <= cnt then
    fxIndex = fxIndex - 1
    local enabled = reaper.TrackFX_GetEnabled(track, fxIndex)
    reaper.TrackFX_SetEnabled(track, fxIndex, not enabled)
    -- set toolbar highlight
    local self = ({reaper.get_action_context()})[4]
    if enabled then  
      reaper.SetToggleCommandState(0, self, 1)
    else
      reaper.SetToggleCommandState(0, self, 0)
    end 
  end
end  
reaper.defer(function () end)

Last edited by Edgemeal; 02-26-2021 at 08:53 PM. Reason: Add error trap for missing track #
Edgemeal is offline   Reply With Quote
Old 02-27-2021, 09:17 AM   #2408
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Edgemeal View Post
Try,....
This is working great, I can't thank you enuff... is it possible to make it toggle float Fx as well? If it's not too much of a hassle, I tried but I couldn't find anything good to copy and paste from which made sense.... made it float but toggle it did not it ended up being the script who said "Nil!"
Kr3eM is offline   Reply With Quote
Old 02-27-2021, 10:18 AM   #2409
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Oh... hold on, I think I actually made it work...

Replaced a bit of the script and inverted the toggle Set in the end to be accurate...

Code:
-- Toggle FX # float for track #
-- File name examples,...
-- Toggle FX 3 float for track 1.lua
-- Toggle FX 2 float for track 2.lua
-- Toggle FX 1 float for track 3.lua

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local trNum = tonumber(name:match("track (%d+)"))
local track = reaper.GetTrack(0,trNum-1)

if track ~= nil then
  local cnt = reaper.TrackFX_GetCount(track) 
  if fxIndex <= cnt then
    fxIndex = fxIndex - 1
	
	------------changed-----------------------
	
    local enabled = reaper.TrackFX_GetFloatingWindow(track, fxIndex, 3)
	
	if enabled then;
	reaper.TrackFX_Show(track, fxIndex, 2);
	
	else;
	reaper.TrackFX_Show(track, fxIndex, 3);
end
	-------------changed--------------------

    -- set toolbar highlight
    local self = ({reaper.get_action_context()})[4]
    if enabled then  
      reaper.SetToggleCommandState(0, self, 0)
    else
		  
      reaper.SetToggleCommandState(0, self, 1)

    end 
 end
end

reaper.defer(function () end)

Last edited by Kr3eM; 02-27-2021 at 10:43 AM. Reason: added code
Kr3eM is offline   Reply With Quote
Old 02-27-2021, 10:35 AM   #2410
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

@Edgemeal

I just wanted to thank you again for your help, very much appreciated.
Kr3eM is offline   Reply With Quote
Old 03-01-2021, 12:17 PM   #2411
strachupl
Human being with feelings
 
strachupl's Avatar
 
Join Date: Jan 2013
Posts: 650
Default

I wonder if there is some other randomizer of FX there.
I know about:


Code:
Script: mpl_Randomize Track FX parameters.lua
and
Code:
Script: kawa_GUI_FxRandomiza.lua

Kawa randomizer work as I want in most cases but I discovered that sometimes it do not randomize some parameters in full scale. For example it randomize delay knob in plugin from 0-50% and do not pick values of 50-100%. In most cases it works but some plugins not. This script is very usefull and have locking values feature. Mpl script don't work in same way but it morph 0-100% in cases that Kawas script not.

Maybe somone know about some other script that is able to randomize FX parameters with locking/securing feature? Thanks
__________________
Love is patient and kind; love does not envy or boast; it is not arrogant or rude.
It does not insist on its own way; it is not irritable or resentful;
it does not rejoice at wrongdoing, but rejoices with the truth. Corinthians 13:4-6
strachupl is offline   Reply With Quote
Old 03-02-2021, 04:30 AM   #2412
zamboknee
Human being with feelings
 
Join Date: Jun 2009
Posts: 209
Default

Would like a script (already existing for MAC?) that allows me to adjust the font of time selections.
see attachment from post here. https://forum.cockos.com/showthread.php?t=248594
zamboknee is offline   Reply With Quote
Old 03-02-2021, 08:40 AM   #2413
Loulou92
Human being with feelings
 
Loulou92's Avatar
 
Join Date: Sep 2015
Location: Paris
Posts: 544
Default

Hello !

I try to spare my CPU a little bit & I notice that the monitoring fx take a lot of resources here. I wish I could create cycle actions to put some of the monitoring FX offline/online. Currently we can bypass and unbypass in the action list.

"Set monitoring FX number n offline"

"Set monitoring FX number n online"

Any input appreciated !!
xxxxxxxxxxxxxxxxx
Loulou92 is offline   Reply With Quote
Old 03-02-2021, 10:34 AM   #2414
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Loulou92 View Post
Hello !

I try to spare my CPU a little bit & I notice that the monitoring fx take a lot of resources here. I wish I could create cycle actions to put some of the monitoring FX offline/online. Currently we can bypass and unbypass in the action list.

"Set monitoring FX number n offline"

"Set monitoring FX number n online"

Any input appreciated !!
xxxxxxxxxxxxxxxxx

I made some minor changes to Edgemeal's script, try this and see if it works...

EDIT: However, not sure if it makes that much difference than bypass in regards to save CPU, but perhaps there are certain plugins that will.

Code:
-- Toggle FX # offline for Monitor FX
-- Copy this script file and rename the FX # for,
-- the FX slot number you want to toggle offline.
-- For example,
-- Toggle FX 3 offline for Monitor FX.lua
-- Toggle FX 4 offline for Monitor FX.lua
-- Toggle FX 5 offline for Monitor FX.lua
-- etc, etc...

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local track = reaper.GetMasterTrack()
local cnt = reaper.TrackFX_GetRecCount(track)
if fxIndex <= cnt then
  fxIndex = (0x1000000 + (fxIndex-1))
   local enabled = reaper.TrackFX_GetOffline(track, fxIndex, 1)
  reaper.TrackFX_SetOffline(track, fxIndex, not enabled)
  -- set toolbar highlight
  local self = ({reaper.get_action_context()})[4]
  if enabled then  
    reaper.SetToggleCommandState(1, self, 1)
  else
    reaper.SetToggleCommandState(1, self, 0)
  end
end
reaper.defer(function () end)

Last edited by Kr3eM; 03-02-2021 at 10:42 AM.
Kr3eM is offline   Reply With Quote
Old 03-02-2021, 01:15 PM   #2415
Loulou92
Human being with feelings
 
Loulou92's Avatar
 
Join Date: Sep 2015
Location: Paris
Posts: 544
Default

Quote:
Originally Posted by Kr3eM View Post
I made some minor changes to Edgemeal's script, try this and see if it works...

EDIT: However, not sure if it makes that much difference than bypass in regards to save CPU, but perhaps there are certain plugins that will.

Code:
-- Toggle FX # offline for Monitor FX
-- Copy this script file and rename the FX # for,
-- the FX slot number you want to toggle offline.
-- For example,
-- Toggle FX 3 offline for Monitor FX.lua
-- Toggle FX 4 offline for Monitor FX.lua
-- Toggle FX 5 offline for Monitor FX.lua
-- etc, etc...

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local track = reaper.GetMasterTrack()
local cnt = reaper.TrackFX_GetRecCount(track)
if fxIndex <= cnt then
  fxIndex = (0x1000000 + (fxIndex-1))
   local enabled = reaper.TrackFX_GetOffline(track, fxIndex, 1)
  reaper.TrackFX_SetOffline(track, fxIndex, not enabled)
  -- set toolbar highlight
  local self = ({reaper.get_action_context()})[4]
  if enabled then  
    reaper.SetToggleCommandState(1, self, 1)
  else
    reaper.SetToggleCommandState(1, self, 0)
  end
end
reaper.defer(function () end)
Thank you ! your script works. May I ask for versions of this script that doesn't toggle ? One script that put offline, and one script that put online ? That would be very helpfull to me ! Althought I think I understand the basic of the script, I'm not sure how to mod it.
Loulou92 is offline   Reply With Quote
Old 03-02-2021, 03:58 PM   #2416
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Loulou92 View Post
May I ask for versions of this script that doesn't toggle ? One script that put offline, and one script that put online ?
Code:
-- Set FX # offline for Monitor FX
-- Copy this script file and rename the FX # for,
-- the FX slot number you want to set offline.
-- For example,
-- Set FX 3 offline for Monitor FX.lua
-- Set FX 4 offline for Monitor FX.lua
-- Set FX 5 offline for Monitor FX.lua
-- etc, etc...

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local track = reaper.GetMasterTrack()
local cnt = reaper.TrackFX_GetRecCount(track)
if fxIndex <= cnt then
  fxIndex = (0x1000000 + (fxIndex-1))
  reaper.TrackFX_SetOffline(track, fxIndex, 1)
end

and for Online
Code:
-- Set FX # online for Monitor FX
-- Copy this script file and rename the FX # for,
-- the FX slot number you want to set online.
-- For example,
-- Set FX 3 online for Monitor FX.lua
-- Set FX 4 online for Monitor FX.lua
-- Set FX 5 online for Monitor FX.lua
-- etc, etc...

local name = ({reaper.get_action_context()})[2]:match("([^/\\_]+).lua$")
local fxIndex = tonumber(name:match("FX (%d+)"))
local track = reaper.GetMasterTrack()
local cnt = reaper.TrackFX_GetRecCount(track)
if fxIndex <= cnt then
  fxIndex = (0x1000000 + (fxIndex-1))
  reaper.TrackFX_SetOffline(track, fxIndex, 0)
end

Last edited by Kr3eM; 03-02-2021 at 05:19 PM.
Kr3eM is offline   Reply With Quote
Old 03-02-2021, 05:10 PM   #2417
Loulou92
Human being with feelings
 
Loulou92's Avatar
 
Join Date: Sep 2015
Location: Paris
Posts: 544
Default

Thank you so much Kr3eM ! The last two scripts will be used a lot and sure enough other readers of the thread will find use for the toggle version too.

Conerning CPU use of offline versus bypass, I notice a difference with the Sonarwork plugin. The offline is really welcome. My PC ventirad thanks you.
Loulou92 is offline   Reply With Quote
Old 03-02-2021, 05:18 PM   #2418
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Loulou92 View Post
Thank you so much Kr3eM ! The last two scripts will be used a lot and sure enough other readers of the thread will find use for the toggle version too.

Conerning CPU use of offline versus bypass, I notice a difference with the Sonarwork plugin. The offline is really welcome. My PC ventirad thanks you.
Glad to help, can't code by any stretch, most of the work is credited to Edgemeal... I just Frankenstein'ed it.

Also, edited the script... you can delete the last row
"reaper.defer(function () end)"

Thanks for letting me know about Sonarworks.

Last edited by Kr3eM; 03-02-2021 at 05:21 PM. Reason: spelling skills = not
Kr3eM is offline   Reply With Quote
Old 03-05-2021, 10:55 AM   #2419
buddhajuke
Human being with feelings
 
Join Date: Jun 2012
Posts: 277
Default Select track(s) sent to hardware output 12 (or any number)

Hi, looking for a script that selects the track or tracks routed or sent to a hardware output x. I have a 40 channel analog console mixer, and 30 channels of i/o routed to and from that mixer.

It's an old mixer, and the only midi functionality is the mutes. You can turn the mutes on and off with midi. That's it. So I am always fiddling with ways to use those buttons to also select the corresponding track in REAPER, but I don't want to simply say if mute 23 is pressed, then selact track 23, because I am constantly moving tracks around, so that won't work. But if the mute can select the track that's routed to it, that would be fantastic.
buddhajuke is offline   Reply With Quote
Old 03-06-2021, 04:16 AM   #2420
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

I was trying to make a custom action that reverses an item and the envelope points directly under it and was somehow surprised that while we have "Toggle Take Reverse" and "Envelope: Reverse Points" we don't have "Select envelope points under selected item" to put inbetween.

So could someone script this? A reverse function that does not only reverse an item but also the envelope points of all envelope lanes underneath it (not the whole lanes tough, just the part under the item). Or perhaps simply "Select envelope points under selected item" which can be used for my purpose as well as other purposes.
Phazma is offline   Reply With Quote
Old 03-09-2021, 03:56 AM   #2421
hans
Human being with feelings
 
Join Date: Aug 2020
Posts: 281
Default Select all Adjacent Items

Hi!

I'm in need of a script that can select all adjacent items around a selected item. I want this to affect items that are next to each other and crossfaded items to left and right of the selected item.

Any ideas?

Last edited by hans; 03-09-2021 at 05:55 AM.
hans is offline   Reply With Quote
Old 03-11-2021, 09:09 AM   #2422
hans
Human being with feelings
 
Join Date: Aug 2020
Posts: 281
Default

I think this one would be beneficial:

Copy Selected Item Name / Rename Selected Item From Clipboard
hans is offline   Reply With Quote
Old 03-11-2021, 10:03 AM   #2423
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,900
Default

@hans

All this already exists
  • Script: X-Raym_Select items adjacent to or overlapping selected items.lua (premium)
  • Script: Archie_Take; Copy Name item active take.lua / Script: nvk_TAKES - Copy take name.lua
  • Script: X-Raym_Rename selected items with clipboard content.lua
You should install common reapack repository to have a full list of existing scripts :P
X-Raym is offline   Reply With Quote
Old 03-11-2021, 10:57 AM   #2424
hans
Human being with feelings
 
Join Date: Aug 2020
Posts: 281
Default

@X-Raym.
Thanks man. Your scripts are great

Oops.

I did have at least your rename selected items with clipboard content,
but not archies repository. I seem to have missed a few. Thanks for letting me know!

I'm having my eyes on your premium pack already...
hans is offline   Reply With Quote
Old 03-11-2021, 11:10 AM   #2425
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

Quote:
Originally Posted by Phazma View Post
Would it be possible to have a script that runs in the background and automatically renames unnamed tracks when a virtual instrument is added to it? For example as soon as I add an instance of Kontakt to an unnamed track the track name turns to "Kontakt"?
Anyone?
Phazma is offline   Reply With Quote
Old 03-11-2021, 02:25 PM   #2426
jrk
Human being with feelings
 
Join Date: Aug 2015
Posts: 2,969
Default

Quote:
Originally Posted by Phazma View Post
Anyone?
Names a track for the first fx VSTi added to it:
eel script

Code:
// Names "unnamed" tracks for their first VSTi / VST3i

function main()
(
	n = CountTracks(0);

	i = 0;
	namestr = #;
	while (i<n)
	(
		trk = GetTrack(0,i);
		GetTrackName(trk, tname);
		
		match("Track %d", tname) ?
		(
			fxn = TrackFX_GetCount(trk);
			j = 0; found = 0;
			while((j<fxn) && !found)
			(
				TrackFX_GetFXName(trk, j, namestr);
			
				match("VST*i: %{new_name}s", namestr)?
				(
					found = 1;
					GetSetMediaTrackInfo_String(trk, "P_NAME", new_name, 1);
				);
				j +=1;
			);		
		);
		i+= 1;
	);
	
	defer("main();");
);

main();
crikey, my tabs have gone very long....
__________________
it's meant to sound like that...

Last edited by jrk; 03-12-2021 at 07:34 AM. Reason: space added to match, was leaving leading space in name
jrk is offline   Reply With Quote
Old 03-11-2021, 05:13 PM   #2427
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

@jrk this is amazing! Thanks a lot!
Phazma is offline   Reply With Quote
Old 03-11-2021, 07:28 PM   #2428
jrk
Human being with feelings
 
Join Date: Aug 2015
Posts: 2,969
Default

you're welcome.
__________________
it's meant to sound like that...
jrk is offline   Reply With Quote
Old 03-12-2021, 07:01 AM   #2429
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

Quote:
Originally Posted by jrk View Post
you're welcome.
Just a small thing.. I have noticed that your script adds a blank space character before the actual VSTi name. Is it possible to get rid of that?
Phazma is offline   Reply With Quote
Old 03-12-2021, 07:29 AM   #2430
jrk
Human being with feelings
 
Join Date: Aug 2015
Posts: 2,969
Default

Good spot!

Try changing
Code:
match("VST*i:%{new_name}s", namestr)?
to
Code:
match("VST*i: %{new_name}s", namestr)?
Note the space before the "%"

Have edited the original, Thanks!
__________________
it's meant to sound like that...
jrk is offline   Reply With Quote
Old 03-12-2021, 07:53 AM   #2431
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

Nice, that worked. No problem, thanks to you for the great script!
Phazma is offline   Reply With Quote
Old 03-13-2021, 02:31 AM   #2432
brk303
Human being with feelings
 
Join Date: Nov 2016
Location: Serbia
Posts: 172
Default

I have a MIDI item with program change messages for selecting patches in my guitar rig.
I have multiple messages across song where certain patch is selected.
I want to change params for multiple program change messages in one action.
For example, I want to change Crunch to Clean in all 10 places where it's specified.

So what I need is input dialog box with:
From: 31
To: 30
OK Cancel

Anyone willing to help ?
brk303 is offline   Reply With Quote
Old 03-13-2021, 03:00 AM   #2433
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,900
Default

@brk303
Check Realearn 2 reaper extension.
X-Raym is offline   Reply With Quote
Old 03-13-2021, 04:59 PM   #2434
MusoBob
Human being with feelings
 
MusoBob's Avatar
 
Join Date: Sep 2014
Posts: 2,643
Default

Quote:
Originally Posted by brk303 View Post
I have a MIDI item with program change messages for selecting patches in my guitar rig.
I have multiple messages across song where certain patch is selected.
I want to change params for multiple program change messages in one action.
For example, I want to change Crunch to Clean in all 10 places where it's specified.

So what I need is input dialog box with:
From: 31
To: 30
OK Cancel

Anyone willing to help ?
See if this works, I only tried it with a few program changes:
Code:
  item = reaper.GetSelectedMediaItem(0, 0)
  
  if not item then
    reaper.MB( "Select a Midi item", "Notice", 0 )
    goto GetMIDIProgramChange_end
  end  
  
  take = reaper.GetActiveTake(item)
  if not reaper.TakeIsMIDI( take ) then 
    reaper.MB( "Select a Midi item", "Notice", 0 )
    goto GetMIDIProgramChange_end 
  end
  
  retval_inputs, retvals_csv = reaper.GetUserInputs( "Set Program to Change", 2, "Select Target,Change to", "30,31" )
  pc_target, pc_set = retvals_csv:match("([^,]+),([^,]+)")
  
  if not retval_inputs then
    goto GetMIDIProgramChange_end
  end   
  
  pc_target,pc_set = retvals_csv:match("([^,]+),([^,]+)") 
  
  _, notecnt = reaper.MIDI_CountEvts( take )

  for i = 1, notecnt +100 do 

    retval, selected, muted, ppqpos, chanmsg, chan, ProgramChange, msg3 = reaper.MIDI_GetCC( take, i )

    if ProgramChange == tonumber(pc_target) then

      reaper.MIDI_InsertCC( take, true, false, ppqpos, 192, chan, tonumber(pc_set), 0)
       
    end  
   
  end
              

  reaper.MIDI_Sort(take)

  ::GetMIDIProgramChange_end::
__________________
ReaTrakStudio Chord Track for Reaper forum
www.reatrak.com
STASH Downloads https://stash.reaper.fm/u/ReaTrak
MusoBob is offline   Reply With Quote
Old 03-19-2021, 05:33 AM   #2435
hans
Human being with feelings
 
Join Date: Aug 2020
Posts: 281
Default

@X-Raym

Script: X-Raym_Select items adjacent to or overlapping selected items.lua (premium)

I was looking at your screenshot over at your website. I'm pretty sure it can do what I want it to do, but the screenshot and gif over on your site isn't really clear to me. Seems to be moving stuff, which I don't want.

I Want to be able to just select an item and then have the script to select all the items which are directly next to it and crossfaded. Is this possible with that script?

Thank you!
hans is offline   Reply With Quote
Old 03-20-2021, 08:09 AM   #2436
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default FX Chains as Popup Menu?

Is it possible to make a popup menu that read/Display the FX Chains folder content and to be able to add clicked chain to selected track ?
Kr3eM is offline   Reply With Quote
Old 03-20-2021, 12:42 PM   #2437
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by Kr3eM View Post
Is it possible to make a popup menu that read/Display the FX Chains folder content and to be able to add clicked chain to selected track ?
REAPER can already do it, but you have to make sure the "FX Chains" folder is visible in the FX Browser (options > left pane list), then you can right click on Mixer or Track FX button and you should see the 'fx chains' sub menu at the top of that context menu.
Edgemeal is offline   Reply With Quote
Old 03-20-2021, 03:21 PM   #2438
Kr3eM
Human being with feelings
 
Kr3eM's Avatar
 
Join Date: Apr 2019
Posts: 231
Default

Quote:
Originally Posted by Edgemeal View Post
REAPER can already do it, but you have to make sure the "FX Chains" folder is visible in the FX Browser (options > left pane list), then you can right click on Mixer or Track FX button and you should see the 'fx chains' sub menu at the top of that context menu.
I know, it's the sub menu I want to get away from, I'm looking for a way to display the root of FX chains directly...unless there's a way to display fX Chains in 'custome' FX Folders without them having display their path as the name, but I doubt it and I can't have all my FX chains listed in the root directory of the FX Chains folder without any sub folders, it will take ages to scroll...so it makes a mess to have any of FX chains in any custome Folders.

I was using 'amagalma_Smart track layout picker' and thought that would be nice thing to have a shortcut key to display the FX Chains directory.

Last edited by Kr3eM; 03-21-2021 at 05:09 PM. Reason: spelling
Kr3eM is offline   Reply With Quote
Old 03-22-2021, 02:50 AM   #2439
Phazma
Human being with feelings
 
Join Date: Jun 2019
Posts: 2,875
Default

Quote:
Originally Posted by daniellumertz View Post
here they need to have the exact same length to work the mouse mod. I would +1 if there is already an FR to it work in all selected makes sense to me
Quote:
Originally Posted by sonictim View Post
I agree... To me, the expected behavior is for it to work no matter the length of the fades.. +1
Sorry, a bit late and unrelated to script requests, but if you are still interested to support this FR (which you helped script around on page 59 of this thread), I have just posted it in FR forum: https://forum.cockos.com/showthread.php?t=251179
Phazma is offline   Reply With Quote
Old 04-05-2021, 10:15 AM   #2440
Gass n Klang
Human being with feelings
 
Gass n Klang's Avatar
 
Join Date: Nov 2015
Location: Cologne
Posts: 1,640
Default REQUEST: Temporary markers for take comparisons.

hey guys,
I need three scripts:

1) The first script should create a named marker at edit cursor position or alternativly move - if already existing - it to edit cursor position
2) The second script should delete all markers named by a certain string
3) The third one should jump to a specific marker (found by its name)

Where do I need it for?
classical music is recorded without fix tempo. Thus takes are recorded without the use of reaper's take system just one after the other. To compare certain parts, I'd like to have "temporary markers" (as existing in sequoia) that are created at equal parts of different takes. That allows us to jump between them... So I think I just called them " *TEMP 1 " (2, 3, 4, 5, ...) and assign auto-coloring via SWS. Would be great if someone could help me with that.

Bonus request: If the temp markers could have big ID numbers (let's say 1000 and above) we'd be sure they not destroy marker ID order of our other markers that could be neeeded for any reason.
__________________
https://juliusgass.de

Last edited by Gass n Klang; 04-06-2021 at 01:08 AM.
Gass n Klang 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:35 AM.


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