Go Back   Cockos Incorporated Forums > REAPER Forums > newbieland

Reply
 
Thread Tools Display Modes
Old 06-26-2019, 06:26 AM   #1
jlkcz
Human being with feelings
 
Join Date: Sep 2018
Posts: 2
Default Which actions adds points to take volume envelope

I am using REAPER for editing spoken word (as a radio journalist) and I have a reasonable use for making custom actions which would add multiple points on the take volume envelope on an item, but I can't find such an action.

Is there such an action? Is to possible to make such a thing?

Clarification: Basically, I want to do this sequence

Go to start of item
Move cursor 2 seconds further to the left
Add point to take volume envelope
Move cursor 1 second further to the left
point to take volume envelope
Move this point to -20 dB
Jump to the beginning of selected item

Highlighted actions are actions I am not sure how to do

Last edited by jlkcz; 06-26-2019 at 08:18 AM.
jlkcz is offline   Reply With Quote
Old 06-26-2019, 08:50 AM   #2
Pinknoise
Human being with feelings
 
Pinknoise's Avatar
 
Join Date: Aug 2012
Location: Around Montréal
Posts: 869
Default

It's not exactly what you are looking for but in that post:
https://forum.cockos.com/showthread.php?t=219267

The last macro posted has a series of action that I think would be similar to what you are trying to accomplish. You might want to check it out and edit to your liking.
Pinknoise is offline   Reply With Quote
Old 06-26-2019, 11:22 PM   #3
jlkcz
Human being with feelings
 
Join Date: Sep 2018
Posts: 2
Default

Quote:
Originally Posted by Pinknoise View Post
It's not exactly what you are looking for but in that post:
https://forum.cockos.com/showthread.php?t=219267

The last macro posted has a series of action that I think would be similar to what you are trying to accomplish. You might want to check it out and edit to your liking.
Thank you, that was a good inspiration. For those, who are considering doing something similar, I gutted spk77 script from this comment: https://forum.cockos.com/showthread.php?t=143902

The result looks like this:

Code:
// Add set points to take volume envelope

#new_chunk_header = "<TRACK_ENVELOPE_UNKNOWN
ACT 1
VIS 1 1 1
LANEHEIGHT 0 0
ARM 0
DEFSHAPE 0 -1 -1
";

#new_chunk_points = "";

#new_chunk_tail = ">
";

function get_set_envelope(take, envelope_name) local(env)
(
  // if take's "take volume envelope" doesn't exist:
  (env = GetTakeEnvelopeByName(take, envelope_name) == 0) ? (
    envelope_name == "Volume" ? Main_OnCommand(NamedCommandLookup("_S&M_TAKEENV1"), 0); // show take volume envelope
  );
  // now it should exist -> get take's "take envelope pointer":
  (env = GetTakeEnvelopeByName(take, envelope_name)) ? (
    GetSetEnvelopeState(env, #new_chunk);
  );
);

function generate_point_lines(take) local(i)
(
    #new_chunk_points += "PT 2.2 1.000000 0\n";
    #new_chunk_points += "PT 3.0 0.2500000 0\n";
);

function join_lines()
(
  #new_chunk += #new_chunk_header;
  #new_chunk += #new_chunk_points;
  #new_chunk += #new_chunk_tail;
  //msg_s(#new_chunk);
);

function main()
(
  (take = GetActiveTake(GetSelectedMediaItem(0, 0))) ? (
    generate_point_lines();
    join_lines();
    get_set_envelope(take, "Volume");
    
);

main();
You can set your own points in generate_point_lines() where the format is
Code:
PT time-in-seconds loudness
jlkcz 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 09:40 AM.


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