Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER General Discussion Forum

Reply
 
Thread Tools Display Modes
Old 01-31-2019, 02:04 PM   #1
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default Action: Show/Toggle Fx chain for item take?

I want to show/toggle the fx chain of an item take, but i didn't find any action other than Show Fx chain for item take.

Does anyone know if there's a script to do this or to close/hide the fx chain from an item take?
Vagelis is offline   Reply With Quote
Old 01-31-2019, 02:24 PM   #2
foxAsteria
Human being with feelings
 
foxAsteria's Avatar
 
Join Date: Dec 2009
Location: Oblivion
Posts: 10,271
Default

Well it's not a perfect solution, but you can make a cycle action and just close all fx chain windows as the second step.
__________________
foxyyymusic
foxAsteria is online now   Reply With Quote
Old 01-31-2019, 02:47 PM   #3
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

I tried the action you mention but it didn't close the fx chain of the item.Maybe because it works only for the track fx chain?
Vagelis is offline   Reply With Quote
Old 01-31-2019, 04:48 PM   #4
foxAsteria
Human being with feelings
 
foxAsteria's Avatar
 
Join Date: Dec 2009
Location: Oblivion
Posts: 10,271
Default

Maybe, yea. What I've done is assign 'toggle close all floating windows' to esc key to deal with all of them at once. You may need to add 'focus main window' before it in a custom action.
__________________
foxyyymusic
foxAsteria is online now   Reply With Quote
Old 01-31-2019, 06:23 PM   #5
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by Vagelis View Post
Does anyone know if there's a script to do this or to close/hide the fx chain from an item take?

Try something like,..

Code:
-- Toggle FX chain show for selected item

item = reaper.GetSelectedMediaItem(0, 0) -- Get 1st selected item

if item then
  take = reaper.GetActiveTake(item)
  index_visible = reaper.TakeFX_GetChainVisible(take) 
  if index_visible >= 0 then -- take fx chain is visible  
    reaper.TakeFX_Show(take, index_visible, 0) -- showflag=0 for hidechain, =1 for show chain(index valid), =2 for hide floating window(index valid), =3 for show floating window (index valid)
 else
    reaper.Main_OnCommand(40638, 0) -- Item: Show FX chain for item take
  end
end
Edgemeal is offline   Reply With Quote
Old 02-01-2019, 05:38 AM   #6
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

Edgemeal this is gold thank you very much!!
It toggles perfectly the fx window when a fx is on the item take.

By the way when there's no fx on the item take, the action opens the fx browser and doesn't close/toggle the window till i add a fx.

I'd like to ask if it's possible to show/toggle the fx browser even when there's no fx on the item take.

Big thanks again!!
Vagelis is offline   Reply With Quote
Old 02-01-2019, 08:14 AM   #7
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by Vagelis View Post
I'd like to ask if it's possible to show/toggle the fx browser even when there's no fx on the item take.
Only way I know off hand would be to use js_ReaScriptAPI extension to find those 'add fx to item' windows and close them, so maybe something like this,..

Code:
if not reaper.APIExists("JS_Window_Find") then
  reaper.MB("js_ReaScriptAPI extension is required for this script.", "Missing API", 0)
  return
end

local item = reaper.GetSelectedMediaItem(0, 0) -- Get 1st selected item

if item then
  local take = reaper.GetActiveTake(item)
  local index = reaper.TakeFX_GetChainVisible(take)
  if index >= 0 then -- take fx chain is visible
    reaper.TakeFX_Show(take, index, 0) -- showflag=0 for hidechain, =1 for show chain(index valid), =2 for hide floating window(index valid), =3 for show floating window (index valid)
  else  -- close 'fx item' windows if found
    local hwnd1 = reaper.JS_Window_Find(reaper.JS_Localize("Add FX to: Item", "common"), false)
    local hwnd2 = reaper.JS_Window_Find(reaper.JS_Localize("FX: Item", "common"), false)
    if hwnd1 or hwnd2 then
      if hwnd1 then reaper.JS_WindowMessage_Post(hwnd1, "WM_CLOSE", 0,0,0,0) end
      if hwnd2 then reaper.JS_WindowMessage_Post(hwnd2, "WM_CLOSE", 0,0,0,0) end
    else -- show fx chain/fx add browser
      reaper.Main_OnCommand(40638, 0) -- Item: Show FX chain for item take
    end 
  end
end

Last edited by Edgemeal; 02-01-2019 at 09:26 AM. Reason: add comments
Edgemeal is offline   Reply With Quote
Old 02-01-2019, 08:46 AM   #8
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

Sir you 're awesome!!
Vagelis is offline   Reply With Quote
Old 02-01-2019, 10:56 AM   #9
RJHollins
Human being with feelings
 
Join Date: Dec 2011
Posts: 2,167
Default

Quote:
Originally Posted by Edgemeal View Post
Only way I know off hand would be to use js_ReaScriptAPI extension to find those 'add fx to item' windows and close them, so maybe something like this,..

Code:
if not reaper.APIExists("JS_Window_Find") then
  reaper.MB("js_ReaScriptAPI extension is required for this script.", "Missing API", 0)
  return
end

local item = reaper.GetSelectedMediaItem(0, 0) -- Get 1st selected item

if item then
  local take = reaper.GetActiveTake(item)
  local index = reaper.TakeFX_GetChainVisible(take)
  if index >= 0 then -- take fx chain is visible
    reaper.TakeFX_Show(take, index, 0) -- showflag=0 for hidechain, =1 for show chain(index valid), =2 for hide floating window(index valid), =3 for show floating window (index valid)
  else  -- close 'fx item' windows if found
    local hwnd1 = reaper.JS_Window_Find(reaper.JS_Localize("Add FX to: Item", "common"), false)
    local hwnd2 = reaper.JS_Window_Find(reaper.JS_Localize("FX: Item", "common"), false)
    if hwnd1 or hwnd2 then
      if hwnd1 then reaper.JS_WindowMessage_Post(hwnd1, "WM_CLOSE", 0,0,0,0) end
      if hwnd2 then reaper.JS_WindowMessage_Post(hwnd2, "WM_CLOSE", 0,0,0,0) end
    else -- show fx chain/fx add browser
      reaper.Main_OnCommand(40638, 0) -- Item: Show FX chain for item take
    end 
  end
end
Will this be available with ReaPack ?
RJHollins is offline   Reply With Quote
Old 02-01-2019, 11:37 AM   #10
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by RJHollins View Post
Will this be available with ReaPack ?
IMO it shouldn't be, its really a hack since any window with matching title bar text would get closed. Maybe someone else knows a better way?
Edgemeal is offline   Reply With Quote
Old 09-28-2021, 04:19 AM   #11
kris.audioplanet
Human being with feelings
 
Join Date: Feb 2019
Location: Poland
Posts: 137
Default

Is there a way to hide item FX names on the item title bar itself?
kris.audioplanet is offline   Reply With Quote
Old 09-28-2021, 08:33 AM   #12
Edgemeal
Human being with feelings
 
Edgemeal's Avatar
 
Join Date: Apr 2016
Location: ASU`ogacihC
Posts: 3,921
Default

Quote:
Originally Posted by kris.audioplanet View Post
Is there a way to hide item FX names on the item title bar itself?
I don't see an option to hide fx names on items, only the item name, Maybe do a Feature Request?
Edgemeal 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 06:34 PM.


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