Go Back   Cockos Incorporated Forums > REAPER Forums > ReaScript, JSFX, REAPER Plug-in Extensions, Developer Forum

Reply
 
Thread Tools Display Modes
Old 05-28-2021, 09:35 AM   #1
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default [Update] MK Shaper/Stutter 1.30 - lua script for quick envelope operations.

МАНУАЛ НА РУССКОМ ЗДЕСЬ: https://forum.cockos.com/showthread.php?p=2450619



MK Shaper/Stutter is a script for quick envelope operations based on transients or rhythm grid.

Features:

  • The script is based on the time-tested MK Slicer.
  • Completely non-destructive audio processing based on envelopes manipulations. Realtime envelope operations.
  • Basic operations: Transient or Grid shaping (Ableton Sampler like), emphasizing or suppressing attacks, shortening the tails of sounds, gating percussion, steady rhythmic pulsation (stutter), sidechain pulsation based on transients or grid. Working with the grid also includes triplets and swing.
  • Ability to work with multitracks. Ability to work with many items. Ability to work with MIDI items (only in Grid mode).
  • The Attack parameter depends on the Velocity of the transients. Several modes are available.


System requirements:

Current version of REAPER and SWS. Not tested (but may well work) with older versions.

Video: https://youtu.be/wmGxJgXA7sI


Instructions for use:

1. Select one track and select the area with the item. Or: just select the item(s) on the same track without selecting an area. The script will not start, several tracks are selected.
2. Run the script.
3. Done! You can work. To form envelopes click "Shape".
To cancel an actions, use "Reset" button. Reset sliders to default: Ctrl + Click. Fine tune: Shift + Drag(or MouseWheel). Exit the script: Esc, Space - Play.
Also, after running the script, you can select the track on which you want to form an envelope and click "Shape".

In a waveform window:
Mouswheel or Left / Right keys - Horizontal Zoom,
Ctrl (Shift) + Mouswheel or Up / Down keys - Vertical Zoom,
Middle Drag or Left Drag - Move View (Scroll),
Left Click - Set Edit Cursor,
Shift + Left Drag - Move Marker,
Ctrl + Left Drag - Change Velocity,
Shift + Ctrl + Left Drag - Move Marker and Change Velocity,
Right Click on Marker - Delete Marker,

Alternative launch option:

1. Do not select items/area before running the script. Run the script.
2. Select the desired item(s)/area and click the "Get Selection" button.
3.etc.

Working with multitrack:

1. Select one track and select the area with the item. Or: just select the item(s) on the same track without selecting an area. The script will not start, several tracks are selected.
2. Run the script.
3. Select the rest tracks in the multitrack. Your workspace will be set equal to the length of an item selected at the moment you start the script.
4. Done! You can work. To form envelopes click "Shape".


Important!

For the script to work correctly, it is OBLIGATORY for the items to start from the beginning of the bar.
If there are already envelope points in the script area, the script will delete them. If necessary, you can return them with UNDO after closing the script.
Also, do not forget to save before work. Just in case.

What does the Reset button do?
"Reset" resets the envelope to its original state, but only within the scope of the script (items or selection border). If there were already envelope points in the workspace before starting the script, Reset will not restore them. To do this, you can use UNDO after closing the script.

Tips to improve performance.
The script is quite well optimized and will work quickly even on slow systems, but there are things that are important to know.
If the item Rate is changed, this will noticeably slow down the script. On large projects, you can pre-make glue for items with a changed Rate to increase the speed of script work.
The speed of the script also depends on the amount of processed material. Long parts and a large number of tracks in a multitrack can significantly slow down an old computer. If you work with large trackings, I recommend to process them in parts - blocks of 30-60sec.
Additional tip: how to decrease script start time.


Recommendations for setup and use:

Detector:

Most of the default settings are set to be suitable for a large amount of material so that you could successfully detect transients immediately out of the box.
For percussions and plucked string instruments, the Low Cut boost to 2500Hz+ often works well.
For multitrack live drums (Kick and Snare guide track), Low Cut 200Hz and Hi Cut 4500Hz settings are well suited.
For the lowest tones, such as SubBass, SubKick or 808 bass, I recommend to lower the value of Low Cut to 20-60Hz.
The colours of the original waveform and filtered are different, this allows you to see what part of the signal you want to send to the detector.
Please note: the settings of the filters and levels do not affect the sound in any way, this is just what comes to the detector!

Sensitivity, Retrig and Reduce are not the most important settings but they may be handy in your work when the Threshold and Filters controls are not enough.
If you need more sensitivity, you can reduce the value of Sensitivity parameter. Sometimes reduction by one dB can help to detect additional transients. And on the opposite - when the parameter is increased, it helps to reduce sensitivity.
Retrig is similar to the previous parameter, it is also resolution but working "horizontally". If you have many transients you don't want next to the main ones, you can increase the value of this parameter to fix this.
Reduce - reduces the number of transients, from the quietest sounds (when the slider is on the right) to the loudest (the slider is on the left). In trigger mode, when the Velocity circles are displayed, its operation is clearly visible.
Note: the Range slider does not affect the Reduce action, despite the fact that it visually displaces the Velocity levels.

Operations with envelopes:

Floor - controls the strength of the effect on the sound, similar to dry/wet. Modes: Flat (default), Rise (raising Floor from beginning to end) and Fall (lowering Floor from beginning to end).
Attack - attack time after transient. Modes: Fixed (default), By Vel - increasing the velocity increases the attack time. By Vel Inv. - increasing velocity decreases attack time.
Shape - the shape of the Release envelope. Settings: Bias - shift of release division points. By default, each release is split exactly in the middle. Bias Threshold - turn off the dividing points below a certain time threshold.
Invert - invert all points vertically (sidechain mode).
Shift - shift all points by half the grid step (off-beat) in Grid mode.


Some menu items ">":

Track Envelope - if active, the envelope is formed on the track. If disabled, the envelope is formed on the item.
Pre-FX Track Volume - Pre-FX envelope, if active. Post-FX envelope if disabled.
Both of these settings do not affect MIDI items. For MIDI, only the standard Volume envelope is available.

High Precision (Slow, Restart required) - precise, but slower script performance. Recommended when working with multiple items: it helps to remove artifacts and false transients between items.



The script is available in ReaPack.

Don't forget, scripts are developed and supported only thanks to your donations. Please donate.

DONATION (BuyMeACoffee)
DONATION (YooMoney)

Last edited by cool; 02-09-2024 at 10:45 AM.
cool is online now   Reply With Quote
Old 05-28-2021, 09:36 AM   #2
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

update 2/2024
All listed Issues have been fixed.


Known Issues.
Unfortunately, the script code turned out to be much more complicated than I initially thought and some things (yet?) I cannot fix:

Some issues with "Item Envelope" mode.
The script can create extra/erroneous points at the beginning and end of items or selection area.
Not yet implemented Razor Edit.
The script does not work if there is no item in the selection area.
Inserting transient markers does not work. Removing and moving is available in the same way as in MK Slicer.
Sorry.

Last edited by cool; 02-09-2024 at 10:46 AM.
cool is online now   Reply With Quote
Old 05-28-2021, 10:59 AM   #3
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

Wow can't wait to try, looks awesome!
Vagelis is online now   Reply With Quote
Old 05-28-2021, 08:49 PM   #4
Pink Wool
Human being with feelings
 
Pink Wool's Avatar
 
Join Date: Apr 2020
Posts: 1,520
Default

Awesome! Slicer is such a cool tool! Can't wait to try this one out too!
Pink Wool is online now   Reply With Quote
Old 06-03-2021, 03:51 AM   #5
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

+Initial release


Demonstration of Script operations:
https://youtu.be/wmGxJgXA7sI



.

Last edited by cool; 06-03-2021 at 04:07 AM.
cool is online now   Reply With Quote
Old 06-03-2021, 12:49 PM   #6
X-Raym
Human being with feelings
 
X-Raym's Avatar
 
Join Date: Apr 2013
Location: France
Posts: 9,900
Default

Very convicing, well done !


And thx for sharing
X-Raym is offline   Reply With Quote
Old 06-03-2021, 02:00 PM   #7
benmrx
Human being with feelings
 
benmrx's Avatar
 
Join Date: Aug 2010
Posts: 396
Default

This is fantastic! So useful. Thank you!!
benmrx is offline   Reply With Quote
Old 06-05-2021, 01:26 AM   #8
ericzang
Human being with feelings
 
ericzang's Avatar
 
Join Date: Mar 2014
Location: Phoenix, AZ
Posts: 488
Default

Super cool, Cool!
ericzang is offline   Reply With Quote
Old 06-05-2021, 05:25 AM   #9
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

You're welcome!
cool is online now   Reply With Quote
Old 06-05-2021, 03:13 PM   #10
daniellumertz
Human being with feelings
 
daniellumertz's Avatar
 
Join Date: Dec 2017
Location: Brazil
Posts: 2,009
Default

Hey cool very nice script I love doing this envelope stuff will make my life much easier, thanks a lottt
daniellumertz is online now   Reply With Quote
Old 02-06-2022, 09:02 AM   #11
juan_r
Human being with feelings
 
juan_r's Avatar
 
Join Date: Oct 2019
Posts: 1,082
Default

Just discovered this one. Cool, @cool!

One request - no sweat if it's too hard. Could we have also dotted durations besides triplets? I mean 3/4, 3/8, 3/16 etc.

EDIT: An additional suggestion. Not asking for a full fledged manual, but there could be a button to bring up a simple text window containing simple instructions - like the first post of this thread, or a part of it. Just so the script can be used offline with more ease.

Last edited by juan_r; 02-06-2022 at 09:08 AM.
juan_r is online now   Reply With Quote
Old 02-06-2022, 09:28 PM   #12
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

Quote:
Originally Posted by juan_r View Post
Just discovered this one. Cool, @cool!

One request - no sweat if it's too hard. Could we have also dotted durations besides triplets? I mean 3/4, 3/8, 3/16 etc.

EDIT: An additional suggestion. Not asking for a full fledged manual, but there could be a button to bring up a simple text window containing simple instructions - like the first post of this thread, or a part of it. Just so the script can be used offline with more ease.

Hi! Thanks for the feedback and suggestions. I'll try to take this into account in the future.

In the near future there will be an update with some major changes and bug fixes. This is what has accumulated over the past year.
cool is online now   Reply With Quote
Old 02-19-2022, 04:53 PM   #13
Reflected
Human being with feelings
 
Reflected's Avatar
 
Join Date: Jul 2009
Posts: 3,295
Default

Very cool!
Reflected is offline   Reply With Quote
Old 02-19-2022, 09:45 PM   #14
Fergler
Human being with feelings
 
Fergler's Avatar
 
Join Date: Jan 2014
Posts: 5,220
Default

Says available in repack, but I don't see a link?
Fergler is offline   Reply With Quote
Old 02-20-2022, 05:51 AM   #15
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

This script is really good and has great potential on becoming even better
I love what it can do already, I was thinking to suggest as a new addition a sequencer mode.
For example to switch the waveform view to a sequencer view, where little boxes would appear as steps.(similar to megababy for example)
Then drawing on these boxes would create envelope shapes relative to the grid division we choose, so we could draw exactly where we want and make rhythmic patterns.
FL studio has a similar tool as well and is great for that purpose.
What do you think of this idea, would it be possible?

For the cherry on top, if it could support automation items for this function would be really really good!
Vagelis is online now   Reply With Quote
Old 02-24-2022, 09:19 AM   #16
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

Quote:
Originally Posted by Fergler View Post
Says available in repack, but I don't see a link?
Hello. The script is available in ReaPack, nothing else is required.


Quote:
Originally Posted by Vagelis View Post
This script is really good and has great potential on becoming even better
I love what it can do already, I was thinking to suggest as a new addition a sequencer mode.
For example to switch the waveform view to a sequencer view, where little boxes would appear as steps.(similar to megababy for example)
Then drawing on these boxes would create envelope shapes relative to the grid division we choose, so we could draw exactly where we want and make rhythmic patterns.
FL studio has a similar tool as well and is great for that purpose.
What do you think of this idea, would it be possible?

For the cherry on top, if it could support automation items for this function would be really really good!
Sounds interesting and I've already thought about something similar. At a minimum, the ability to enable/disable beats in grid mode to get trance gate patterns. But I can't promise anything, it can be very difficult to implement.
cool is online now   Reply With Quote
Old 02-24-2022, 09:25 AM   #17
vitalker
Human being with feelings
 
vitalker's Avatar
 
Join Date: Dec 2012
Posts: 13,333
Default

Quote:
Originally Posted by Fergler View Post
Says available in repack, but I don't see a link?
ReaTeam probably, which is installed by default.
vitalker is offline   Reply With Quote
Old 02-25-2022, 02:26 PM   #18
Vagelis
Human being with feelings
 
Vagelis's Avatar
 
Join Date: Oct 2017
Location: Larisa, Greece
Posts: 3,827
Default

Quote:
Originally Posted by cool View Post
Sounds interesting and I've already thought about something similar. At a minimum, the ability to enable/disable beats in grid mode to get trance gate patterns. But I can't promise anything, it can be very difficult to implement.
Thanks for considering at least and i understand that it might be difficult to implement. Full support no matter what
Vagelis is online now   Reply With Quote
Old 02-16-2023, 06:39 PM   #19
skylar_battles
Human being with feelings
 
Join Date: Mar 2022
Posts: 1,522
Default ReaScript Error

Hey!

Just tried to run the script on Reaper 6.75 on my Intel Mac and got this error message which is preventing me from using it:
"attempt to compare nil with number"

Would love to check out this script as well as you know I'm an avid fan of both MK slicer scripts

Let me know if there's any specific testing to do that would be helpful. Thanks.
skylar_battles is offline   Reply With Quote
Old 02-16-2023, 06:53 PM   #20
skylar_battles
Human being with feelings
 
Join Date: Mar 2022
Posts: 1,522
Default

Script works if it is opened and then get selection is pressed but...

it fails to work if the item is selected prior to running the script which then presents the error message and closes.
skylar_battles is offline   Reply With Quote
Old 02-16-2023, 10:10 PM   #21
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

Thank you. The new version fixes a lot of bugs, but I won't find time yet to finish it and publish it. I hope someday it will be finished
cool is online now   Reply With Quote
Old 02-16-2023, 10:21 PM   #22
skylar_battles
Human being with feelings
 
Join Date: Mar 2022
Posts: 1,522
Default

Thanks for the reply! I'll be looking forward to it!
skylar_battles is offline   Reply With Quote
Old 01-22-2024, 12:21 PM   #23
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

A lot of changes. Sorry for delay.



v1.20
+ Added Razor Edit.
+ Now the script can manage any selected envelopes. If the envelope is not selected before running the script, the script will create a volume envelope by default.
+ The name of the active Envelope is now displayed in the script interface.
+ Added envelope selector for Items (Volume, Pan, Pitch).
+ Rise and Fall for the Pan envelope have been adjusted. The Gain control changes the range.
+ The range has been increased and the principle of operation of the Gain regulator has been changed.
+ Added "Soft Attack" option.
+ Significantly improved script performance when processing Selected Area.
+ Reset now correctly removes multitrack envelopes and selected areas.
+ True Stutter mode: When the Shape control is at maximum, the envelope takes on a rectangular shape.
+ Fixed a bug: sometimes in item envelope mode the points were not placed correctly if the item had a changed ratio.
+ Fixed a bug: now changing the Shift option does not cause the script to crash if this is done before pressing the Shape button.
+ Fixed a bug: flickering and incorrect position of item envelope points in Rise and Fall modes.
+ Fixed a bug: points were not placed correctly if the item was placed at the start of the project.
+ Fixed a bug: now the script does not crash when trying to process Empty Items.
+ Fixed a bug: now the point of the first transient is drawn correctly if it is not at the start of the item.
+ Fixed a bug that slowed down the update of the script window when Loop was running.
+ Fixed a bug: now the DestroyAudioAccessor function works correctly.
+ Now loop selection is captured by the script only when controlled from the script interface.
+ The minimum grid and ruler resolution has been limited: now long items and small grid resolutions do not overload the processor.
+ Optimization in general: now the script starts instantly. CPU load reduced by 50% when idle.
+ Controls have been streamlined for more intuitive operation.
+ Work without items: if there are no items in the selected area, the script will run in Grid and Track Envelope mode.
+ Now, when working with midi items and without items, the script runs almost instantly, without wasting resources on processing.
+ Added the option to manage all envelopes at once. When disabled, the script controls only the selected one.
+ Now, when zooming horizontally using the keyboard keys, the waveform is centered on the edit cursor.
+ The minimum HPF value turns off the filter, completely removing filtering artifacts.
+ Increased the maximum waveform window width and main window size limits for better display on large screens.
+ Theme: Added the option "Large Font Size" (Options - User Settings (Advanced)), which increases the font size when the window size is large.
+ Undo Points are now created during envelope generation.
+ Donate service has been changed to valid.
cool is online now   Reply With Quote
Old 02-09-2024, 08:10 AM   #24
cool
Human being with feelings
 
Join Date: Dec 2017
Location: Sunny Siberian Islands
Posts: 962
Default

v1.30
+ Added the ability to set markers manually.
+ Added 4, 2 and Dotted Grid buttons to the Grid selector.
+ Added marker flags for easy mouse dragging without using hotkeys.
+ Theme: New color design, 11 new themes added.
+ Interactive Markers: The active marker is now highlighted on mouseover.
+ Theme: The appearance of the sliders has been changed, some sliders have become frameless.
+ The mouse wheel now resizes the grid when the cursor is over the grid resolution buttons.
+ Now the Sensitivity slider has a conventional scale from 1 to 10 and works more logically: 1 is the minimum sensitivity, 10 is the maximum.
+ The range of Retrig values has been expanded, now the value is not related to tempo.
+ Improved marker capture zoning depending on window size and zoom.
+ Improved zoning for selecting and grabbing the first marker if it is located at the left edge of the window.
+ The area where markers are held during capture has been expanded.
+ Improved location of points at the start and end of an item/selected area of an item.
+ Fixed a bug: now the first marker cannot take a negative value and is always visible.
+ Fixed a bug: the script grid responds to changing the grid size in Reaper.
+ Fixed a bug: now the Triplet Grid status is not reset when switching the grid with the mouse wheel.
+ Added experimental font smoothing option (requires ReaimGUI installation).
+ Sync View option is now in the main menu.
+ Now, if, when running a script, an item or area is not selected, the script does not switch to Grid mode.
+ The Track/Item Envelope switch is now on the control panel.
+ For compatibility and correct operation, extstate data is now written under a new header.
+ Set the correct default value for the Rel.Thr slider.
cool is online now   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:42 AM.


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