|
|
|
02-22-2017, 12:25 PM
|
#1
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Is there an action for toggling take volume envelope visibility?
Hello!
The title says it all! I searched but couldn't find any! Is it there? If not, is it possible with reascript?
Edit: I managed to create one with Reascript. It is on post #19
Last edited by amagalma; 02-24-2017 at 06:41 AM.
|
|
|
02-22-2017, 12:38 PM
|
#2
|
Human being with feelings
Join Date: Aug 2011
Location: Great Lakes, N. A.
Posts: 1,872
|
Here you go:
|
|
|
02-22-2017, 01:34 PM
|
#3
|
Human being with feelings
Join Date: Oct 2010
Location: Charleston, SC
Posts: 12,770
|
I don't see one in your list for a selected take or media item volume envelope.
|
|
|
02-22-2017, 01:38 PM
|
#4
|
Administrator
Join Date: Mar 2007
Location: NY
Posts: 15,750
|
Take: toggle take volume envelope ?
|
|
|
02-22-2017, 02:05 PM
|
#5
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
But this action disables and hides it. I just want to hide, not disable
|
|
|
02-22-2017, 02:07 PM
|
#6
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
And preferably I would prefer it to apply to all takes in project, in order to avoid visual clutter
|
|
|
02-22-2017, 03:15 PM
|
#7
|
Administrator
Join Date: Mar 2007
Location: NY
Posts: 15,750
|
There's currently no way to hide take envelopes. For take envelopes, visible equals active, not visible equals not active.
|
|
|
02-22-2017, 04:29 PM
|
#8
|
Human being with feelings
Join Date: Jan 2010
Location: Kalispell
Posts: 14,745
|
Quote:
Originally Posted by schwa
There's currently no way to hide take envelopes. For take envelopes, visible equals active, not visible equals not active.
|
Yeah, you have to select each take envelope individually and then use the menu to hide it, then they retain their function.
But to show them all again you can select all the items and then use "Take: Toggle take volume envelope" to bring them all back up.
|
|
|
02-23-2017, 04:34 PM
|
#9
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Is it doable with a script? If yes, what would be the function that I should call in order to hide (but not disable) a take's volume?
|
|
|
02-23-2017, 05:15 PM
|
#10
|
Human being with feelings
Join Date: Dec 2014
Location: The Dutch Mountains
Posts: 389
|
Quote:
Originally Posted by amagalma
Is it doable with a script? If yes, what would be the function that I should call in order to hide (but not disable) a take's volume?
|
I do it the other way around... Just show the envelope I want to work on and hide the rest
Maybe this helps.... (absolutely not my script btw)
Code:
-- @description Hide all track envelopes except envelope under mouse cursor
-- @version 1.0
-- @author mpl
-- @website http://forum.cockos.com/member.php?u=70694
-- @changelog
-- + init release
function msg(s) reaper.ShowConsoleMsg(s..'\n') end
function main()
reaper.BR_GetMouseCursorContext()
env_MC = reaper.BR_GetMouseCursorContext_Envelope()
if not env_MC then return end
for tr = 1, reaper.CountTracks(0) do
local track = reaper.GetTrack(0,tr-1)
if track then
for i = 1, reaper.CountTrackEnvelopes( track ) do
local env = reaper.GetTrackEnvelope( track, i-1 )
if env == env_MC then visible = true else visible = false end
local br_env = reaper.BR_EnvAlloc( env, false )
local active, _, armed, inLane, laneHeight, defaultShape, _, _, _, _, faderScaling = reaper.BR_EnvGetProperties( br_env )
reaper.BR_EnvSetProperties( br_env,
active,
visible,
armed,
inLane,
laneHeight,
defaultShape,
faderScaling )
reaper.BR_EnvFree( br_env, true )
end
end
end
end
main()
Last edited by Robert Johnson III; 02-23-2017 at 08:09 PM.
Reason: Code tags
|
|
|
02-23-2017, 06:16 PM
|
#11
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Thanks! But I am talking about Take volume envelopes, not Track volume envelopes.
|
|
|
02-23-2017, 06:19 PM
|
#12
|
Human being with feelings
Join Date: Dec 2014
Location: The Dutch Mountains
Posts: 389
|
Quote:
Originally Posted by amagalma
Thanks! But I am talking about Take volume envelopes, not Track volume envelopes.
|
Oeps! #Dyslexic
|
|
|
02-23-2017, 07:10 PM
|
#13
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
No problem!
I managed to put together this code that is able to hide all takes' volume envelopes in project:
Code:
function Hide_All_Take_VolEnvelope()
local(item_cnt, item_idx, item, take_idx, take_cnt, take, VolEnv, BR_Env,
BR_Env, active,visible,armed, inLane,laneHeight,
defShape, minVal,maxVal,centerVal, type, faderScaling)
(
Undo_BeginBlock();
Main_OnCommand(NamedCommandLookup("_SWS_SAVEALLSELITEMS1"), 0); // save current item selection
SelectAllMediaItems(0, 1);
item_cnt = CountSelectedMediaItems(0);
item_idx=0;
loop(item_cnt,
item = GetSelectedMediaItem(0, item_idx);
take_cnt = CountTakes(item);
take_idx = 0;
loop(take_cnt,
take = GetMediaItemTake(item, take_idx);
VolEnv = GetTakeEnvelopeByName(take,"Volume");
BR_Env = extension_api("BR_EnvAlloc", VolEnv, 0);
extension_api("BR_EnvGetProperties", BR_Env, active,visible,armed, inLane,laneHeight,
defShape, minVal,maxVal,centerVal, type, faderScaling);
visible = 0; // Hide VolEnv
extension_api("BR_EnvSetProperties", BR_Env, active, visible, armed, inLane,laneHeight,
defShape, faderScaling);
extension_api("BR_EnvFree", BR_Env, 1);
take_idx += 1;
);
item_idx+=1;
);
Main_OnCommand(NamedCommandLookup("_SWS_RESTALLSELITEMS1"), 0); // restore item selection
Undo_EndBlock("Hide all take volume envelopes in project", -1);
);
Hide_All_Take_VolEnvelope();
Last edited by amagalma; 02-24-2017 at 05:54 AM.
|
|
|
02-23-2017, 08:03 PM
|
#14
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
What should I add so, that the arrange window updates only after the script has finished?
Last edited by amagalma; 02-24-2017 at 05:56 AM.
|
|
|
02-24-2017, 03:47 AM
|
#15
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Furthermore, I would like it to act like this:
-Check all takes that are visible in the arrange window
-If there is a take volume envelope visible, then hide all take volume envelopes in project (which is to say, do what my script above does)
-If there is none visible, then show all take volume envelopes in project (the opposite of what my script does)
Thanks!
Last edited by amagalma; 02-24-2017 at 04:59 AM.
|
|
|
02-24-2017, 05:01 AM
|
#16
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
I have edited my posts above and managed to put together a working script. But I would like it to do something more difficult. Should I ask for help in the Reascript forum?
|
|
|
02-24-2017, 05:14 AM
|
#17
|
Human being with feelings
Join Date: Jul 2010
Location: Slovakia
Posts: 2,588
|
Quote:
Originally Posted by amagalma
Should I ask for help in the Reascript forum?
|
Probably. In the meantime, here is a searchable documentation I use https://www.extremraym.com/cloud/reascript-doc
|
|
|
02-24-2017, 05:56 AM
|
#18
|
Human being with feelings
Join Date: Apr 2011
Posts: 3,451
|
Thank you!
I already use X-Raym's excellent documentation!
|
|
|
01-22-2020, 08:15 AM
|
#20
|
Human being with feelings
Join Date: Oct 2008
Posts: 424
|
Hi Amagalma -
I've been wanting this as well. Where do I put these .eel files to make use of them?
Nevermind - I found it and THANK YOU. This is great!!
Last edited by cdmstudios; 01-22-2020 at 08:32 AM.
|
|
|
01-22-2020, 10:15 AM
|
#21
|
Human being with feelings
Join Date: Oct 2008
Posts: 424
|
Actually, when I run the Hide script, I get an error:
'BR_EnvFree' argument 1: expected BR_Envelope*
anyone know what that means?
are you supposed to select all items in the project before running this script or anything?
|
|
|
05-30-2020, 10:26 AM
|
#22
|
Human being with feelings
Join Date: Sep 2019
Posts: 1,134
|
Quote:
Originally Posted by cdmstudios
Actually, when I run the Hide script, I get an error:
'BR_EnvFree' argument 1: expected BR_Envelope*
anyone know what that means?
are you supposed to select all items in the project before running this script or anything?
|
Works here. Selection isn't necessary.
|
|
|
05-30-2020, 11:29 AM
|
#23
|
Human being with feelings
Join Date: May 2017
Posts: 3,202
|
Quote:
Originally Posted by schwa
There's currently no way to hide take envelopes. For take envelopes, visible equals active, not visible equals not active.
|
Not true. The visible checkbox does exactly that.
Easy to test.
|
|
|
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 03:20 AM.
|