Helpful ReplyMod Wheel data

Author
wizard71
Max Output Level: -74 dBFS
  • Total Posts : 836
  • Joined: 2012/02/12 05:45:05
  • Location: UK
  • Status: offline
2014/04/28 09:43:09 (permalink)

Mod Wheel data

Is there any way of automatically limiting this within sonar so i could for instance not exceed a value of 90 instead of the 0-127 range that is the norm?.
 
Bibs

http://www.youtube.com/SpaceTimeAces
https://soundcloud.com/space-time-aces
Sonar Platinum - Win 8.1 x64 - Haswell 4770k - ASrock Z87 pro3 - 32gb ram - Fractal design R4 case - 3x HDD 1 USB 2.0 external 1x cr M4 ssd for samples - Octa-capture - Sontronics Aria - Sontronics STC-1s - BX8 monitors - ARC 2 system - Kawai CA63 piano - Kawai MP6 Stage piano - Fender custom Telecaster FMT - Yamaha LL6 - Fender P bass


#1
brundlefly
Max Output Level: 0 dBFS
  • Total Posts : 14250
  • Joined: 2007/09/14 14:57:59
  • Location: Manitou Spgs, Colorado
  • Status: offline
Re: Mod Wheel data 2014/04/28 10:10:36 (permalink)
You can't limit what gets recorded, but you might be able to use a MIDI FX to scale the recorded values on echo/playback. And if it's only about only about playback, it's fairly easy to use Find/Replace to scale them after the fact as well.

SONAR Platinum x64, 2x MOTU 2408/PCIe-424  (24-bit, 48kHz)
Win10, I7-6700K @ 4.0GHz, 24GB DDR4, 2TB HDD, 32GB SSD Cache, GeForce GTX 750Ti, 2x 24" 16:10 IPS Monitors
#2
Anderton
Max Output Level: 0 dBFS
  • Total Posts : 14070
  • Joined: 2003/11/06 14:02:03
  • Status: offline
Re: Mod Wheel data 2014/04/28 13:54:05 (permalink)
Not totally clear from the question what you want, but if you want to limit MIDI data in the same way an audio limiter limits audio, here's how.
 
For example, suppose you want to limit the values to 90.
 
1. Do the following math: (127/maximum value you want) X 100. So (127/90) x 100 = 141.
2. Use Scale Velocity to multiply your data by 141 per cent. Check "percentages" and enter 141 for beginning and end.
3. Now calculate the inverse, (maximum value you want/127) x 100. So (90/127) = 71.4. Use Scale Velocity to multiple your data by 71 per cent.
 
Now anything that was more than 90 will be limited to 90, and anything that was under 90 will maintain its original value.

The first 3 books in "The Musician's Guide to Home Recording" series are available from Hal Leonard and http://www.reverb.com. Listen to my music on http://www.YouTube.com/thecraiganderton, and visit http://www.craiganderton.com. Thanks!
#3
scook
Forum Host
  • Total Posts : 24146
  • Joined: 2005/07/27 13:43:57
  • Location: TX
  • Status: offline
Re: Mod Wheel data 2014/04/28 14:25:45 (permalink)
It should be possible routing the input MIDI signal through MIDICurve and use a virtual MIDI cable (LoopBe1 or loopMIDI) to the synth MIDI track.
#4
robert_e_bone
Moderator
  • Total Posts : 8968
  • Joined: 2007/12/26 22:09:28
  • Location: Palatine, IL
  • Status: offline
Re: Mod Wheel data 2014/04/28 15:00:51 (permalink)
Well, I went ahead and wrote (and tested) a CAL script for you, to allow you to enter in a value for the maximum allowable mod wheel level.
 
Any events in that track that are found to be greater than that maximum allowable level are then set to become that maximum allowable level.
 
So, if you run the script for a given track, it will ask you to enter Mod Wheel Maximum Level, and you enter 99 and hit Enter, it will change any mod wheel values for that track that are greater than 99 to BE 99.
 
If this is what you are looking to do, please send me a PM and I will send you the script.
 
Oh - that was a lovely math exercise, Craig.  :)
 
(sorry, couldn't resist poking some fun - it's actually amazing you thought of that approach)
Bob Bone
 
post edited by robert_e_bone - 2014/04/28 16:09:50

Wisdom is a giant accumulation of "DOH!"
 
Sonar: Platinum (x64), X3 (x64) 
Audio Interfaces: AudioBox 1818VSL, Steinberg UR-22
Computers: 1) i7-2600 k, 32 GB RAM, Windows 8.1 Pro x64 & 2) AMD A-10 7850 32 GB RAM Windows 10 Pro x64
Soft Synths: NI Komplete 8 Ultimate, Arturia V Collection, many others
MIDI Controllers: M-Audio Axiom Pro 61, Keystation 88es
Settings: 24-Bit, Sample Rate 48k, ASIO Buffer Size 128, Total Round Trip Latency 9.7 ms  
#5
wizard71
Max Output Level: -74 dBFS
  • Total Posts : 836
  • Joined: 2012/02/12 05:45:05
  • Location: UK
  • Status: offline
Re: Mod Wheel data 2014/04/28 17:22:53 (permalink)
Wow thats amazing guys, thanks for giving such in depth answers. My reason was that I use LA scoring strings which generally sounds the most realistic between 0-75 on CC1 and as i generally draw in the data post recording i thought it would be easier if i could use the whole depth of the CC window but actually limit the CC max so the top of the window would be around that mark as my eyes find it hard to read the numbers easily on the screen.
 
 
If i could find some way of using the full travel of the mod wheel with this limited range whilst actually recording i would be very happy indeed.
 
The next best thing seems to be the CAL script (that ive never used). The Math part fried my brain :) 
 
Bibs

http://www.youtube.com/SpaceTimeAces
https://soundcloud.com/space-time-aces
Sonar Platinum - Win 8.1 x64 - Haswell 4770k - ASrock Z87 pro3 - 32gb ram - Fractal design R4 case - 3x HDD 1 USB 2.0 external 1x cr M4 ssd for samples - Octa-capture - Sontronics Aria - Sontronics STC-1s - BX8 monitors - ARC 2 system - Kawai CA63 piano - Kawai MP6 Stage piano - Fender custom Telecaster FMT - Yamaha LL6 - Fender P bass


#6
Anderton
Max Output Level: 0 dBFS
  • Total Posts : 14070
  • Joined: 2003/11/06 14:02:03
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:11:02 (permalink)
wizard71
The Math part fried my brain :) 


Well in that case...I have good news and bad news. The good news is that it's possible to compress MIDI exactly as you want, so that a range can be compressed into a smaller range. This works just like audio compression, but with MIDI data. The bad news is that if the limiter math fried your brain, the math for the compression will burn it to a crisp.

The first 3 books in "The Musician's Guide to Home Recording" series are available from Hal Leonard and http://www.reverb.com. Listen to my music on http://www.YouTube.com/thecraiganderton, and visit http://www.craiganderton.com. Thanks!
#7
jatoth
Max Output Level: -83 dBFS
  • Total Posts : 363
  • Joined: 2009/08/12 06:31:35
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:16:19 (permalink)
bibs, can your controller be set to limit the range? I don't know the Kawai but on my Kurz I can set it.
 

John
 
X3e Producer, Sonar Platinum, Sweetwater CreationStation i5 3.1gHz, 12 GB RAM, 500GB SSD OS drive, 1TB SSD audio drive, 1TB archive/misc drive, dual 22" monitors, Windows 7x64, SaffirePro40 (firewire), MOTU MIDI Express XT, Behringer BCF2000, dbx 586, Samson Servo 120a, Yamaha HS80M, Auratone 5c Cubes, Sennheiser HD650, Sony MDR 7509HD, Sony MDR 7506, Kurzweil K2500XS, Roland XP-30, Proteus 2000.
#8
wizard71
Max Output Level: -74 dBFS
  • Total Posts : 836
  • Joined: 2012/02/12 05:45:05
  • Location: UK
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:35:40 (permalink)
Anderton
wizard71
The Math part fried my brain :) 


Well in that case...I have good news and bad news. The good news is that it's possible to compress MIDI exactly as you want, so that a range can be compressed into a smaller range. This works just like audio compression, but with MIDI data. The bad news is that if the limiter math fried your brain, the math for the compression will burn it to a crisp.



I've been scared of numbers ever since i opened a joint bank account with my wife :)
 
Would be interested to hear the Math, so feel free to post, it would be appreciated
 
Jatoth, good idea, i did search the menus but coulnt see anything, will check the manual. Cheers

http://www.youtube.com/SpaceTimeAces
https://soundcloud.com/space-time-aces
Sonar Platinum - Win 8.1 x64 - Haswell 4770k - ASrock Z87 pro3 - 32gb ram - Fractal design R4 case - 3x HDD 1 USB 2.0 external 1x cr M4 ssd for samples - Octa-capture - Sontronics Aria - Sontronics STC-1s - BX8 monitors - ARC 2 system - Kawai CA63 piano - Kawai MP6 Stage piano - Fender custom Telecaster FMT - Yamaha LL6 - Fender P bass


#9
scook
Forum Host
  • Total Posts : 24146
  • Joined: 2005/07/27 13:43:57
  • Location: TX
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:41:04 (permalink)
There is a CAL compressor/limiter script included with SONAR called "C-MPLIMT.CAL" for velocity. For scaling control data there is "C-NTROLR,CAL".
#10
robert_e_bone
Moderator
  • Total Posts : 8968
  • Joined: 2007/12/26 22:09:28
  • Location: Palatine, IL
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:47:36 (permalink)
@wizard71 - "I've been scared of numbers ever since i opened a joint bank account with my wife :)"
 
Nothing to be scared of - it's all HERS, so literally there is NOTHING to be afraid of.  (except her).
 
I just responded to your PM, and sent you the script.  Maybe 15 lines of code, half of which were closing ')'.
 
Bob Bone
 

Wisdom is a giant accumulation of "DOH!"
 
Sonar: Platinum (x64), X3 (x64) 
Audio Interfaces: AudioBox 1818VSL, Steinberg UR-22
Computers: 1) i7-2600 k, 32 GB RAM, Windows 8.1 Pro x64 & 2) AMD A-10 7850 32 GB RAM Windows 10 Pro x64
Soft Synths: NI Komplete 8 Ultimate, Arturia V Collection, many others
MIDI Controllers: M-Audio Axiom Pro 61, Keystation 88es
Settings: 24-Bit, Sample Rate 48k, ASIO Buffer Size 128, Total Round Trip Latency 9.7 ms  
#11
Anderton
Max Output Level: 0 dBFS
  • Total Posts : 14070
  • Joined: 2003/11/06 14:02:03
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:48:43 (permalink)
There can be no other possible explanation regarding scook other than that he has mind-melded with Sonar.

The first 3 books in "The Musician's Guide to Home Recording" series are available from Hal Leonard and http://www.reverb.com. Listen to my music on http://www.YouTube.com/thecraiganderton, and visit http://www.craiganderton.com. Thanks!
#12
scook
Forum Host
  • Total Posts : 24146
  • Joined: 2005/07/27 13:43:57
  • Location: TX
  • Status: offline
Re: Mod Wheel data 2014/04/28 18:55:05 (permalink)
IDK, there is so much of SONAR I don't use and don't understand but it is hard not to pick up pieces here and there after a decade or so of using this stuff. CAL has not changed in years. I did not suggest it from the outset because it is not real-time.
#13
robert_e_bone
Moderator
  • Total Posts : 8968
  • Joined: 2007/12/26 22:09:28
  • Location: Palatine, IL
  • Status: offline
Re: Mod Wheel data 2014/04/28 19:13:55 (permalink) ☄ Helpfulby wizard71 2014/04/29 07:03:24
I have actually amassed a pretty sizable set of doc on using CAL.
 
The kind of thing you were trying to do is super simple, as it is basically a loop through the events, and then just a set of tests to see if the event it is looking at it: 1 - a controller event, 2 - a mod-wheel type of controller event, and 3 - set to a value above the input value, followed by setting it to the input value if appropriate.
 
Existing CAL scripts in the included ones with X3 already have event-looping logic, and at least one of the scripts checks for mod wheel events, so I just pretty much mixed and matched and TA DA.
 
Bob Bone
 

Wisdom is a giant accumulation of "DOH!"
 
Sonar: Platinum (x64), X3 (x64) 
Audio Interfaces: AudioBox 1818VSL, Steinberg UR-22
Computers: 1) i7-2600 k, 32 GB RAM, Windows 8.1 Pro x64 & 2) AMD A-10 7850 32 GB RAM Windows 10 Pro x64
Soft Synths: NI Komplete 8 Ultimate, Arturia V Collection, many others
MIDI Controllers: M-Audio Axiom Pro 61, Keystation 88es
Settings: 24-Bit, Sample Rate 48k, ASIO Buffer Size 128, Total Round Trip Latency 9.7 ms  
#14
wizard71
Max Output Level: -74 dBFS
  • Total Posts : 836
  • Joined: 2012/02/12 05:45:05
  • Location: UK
  • Status: offline
Re: Mod Wheel data 2014/04/29 07:06:32 (permalink)
Thanks very much Bob, this works just as described, very useful indeed :)

http://www.youtube.com/SpaceTimeAces
https://soundcloud.com/space-time-aces
Sonar Platinum - Win 8.1 x64 - Haswell 4770k - ASrock Z87 pro3 - 32gb ram - Fractal design R4 case - 3x HDD 1 USB 2.0 external 1x cr M4 ssd for samples - Octa-capture - Sontronics Aria - Sontronics STC-1s - BX8 monitors - ARC 2 system - Kawai CA63 piano - Kawai MP6 Stage piano - Fender custom Telecaster FMT - Yamaha LL6 - Fender P bass


#15
robert_e_bone
Moderator
  • Total Posts : 8968
  • Joined: 2007/12/26 22:09:28
  • Location: Palatine, IL
  • Status: offline
Re: Mod Wheel data 2014/04/29 08:00:52 (permalink)
Glad I could help - that one was easy.  If anyone else has CAL needs, I would be happy to give them a shot - no guarantees on my being able to reanimate dead tissue, but you never know, so for your CAL needs - post em if ya got em.
 
Bob Bone
 

Wisdom is a giant accumulation of "DOH!"
 
Sonar: Platinum (x64), X3 (x64) 
Audio Interfaces: AudioBox 1818VSL, Steinberg UR-22
Computers: 1) i7-2600 k, 32 GB RAM, Windows 8.1 Pro x64 & 2) AMD A-10 7850 32 GB RAM Windows 10 Pro x64
Soft Synths: NI Komplete 8 Ultimate, Arturia V Collection, many others
MIDI Controllers: M-Audio Axiom Pro 61, Keystation 88es
Settings: 24-Bit, Sample Rate 48k, ASIO Buffer Size 128, Total Round Trip Latency 9.7 ms  
#16
wizard71
Max Output Level: -74 dBFS
  • Total Posts : 836
  • Joined: 2012/02/12 05:45:05
  • Location: UK
  • Status: offline
Re: Mod Wheel data 2014/04/30 04:49:17 (permalink)
Hi Bob, I have another CAL question....
 
If i was to draw a crescendo with CC1 from 0-100 using 100 CC1 commands and then use your CAL script to limit data to 90, then the last 10 data points are all compressed to 90 creating a flat line. Is it possible to maintain the crescendo shape by beginning the data at -10 so only the last 90 count? 
Ive a feeling this isnt possible as its outside the range but hey, you never know :)
 
Bibs

http://www.youtube.com/SpaceTimeAces
https://soundcloud.com/space-time-aces
Sonar Platinum - Win 8.1 x64 - Haswell 4770k - ASrock Z87 pro3 - 32gb ram - Fractal design R4 case - 3x HDD 1 USB 2.0 external 1x cr M4 ssd for samples - Octa-capture - Sontronics Aria - Sontronics STC-1s - BX8 monitors - ARC 2 system - Kawai CA63 piano - Kawai MP6 Stage piano - Fender custom Telecaster FMT - Yamaha LL6 - Fender P bass


#17
robert_e_bone
Moderator
  • Total Posts : 8968
  • Joined: 2007/12/26 22:09:28
  • Location: Palatine, IL
  • Status: offline
Re: Mod Wheel data 2014/04/30 11:14:52 (permalink)
The script I wrote is pretty stupid - meaning there is not much logic involved.  It only directly applied to the original question you had posed.
 
It does not care anything whatsoever about 'range', and literally only blindly sets anything found above the entered input value to that value.  This is why those last 10 events would all be set to a flat line.
 
I understand that you get a flat line for whatever events are found in excess of the value you input, but do not understand from your comment "Is it possible to maintain the crescendo shape by beginning the data at -10 so only the last 90 count? ".
 
It is easy enough to alter the script, but I need to better understand how you want the values changed.
 
Here is the current logic of the script:
 
1.  Get an input value from the user, that will represent the maximum allowable mod wheel level.
2.  Loop through all events for the selected midi track, with the following applied to every event.
3.  IF event is a Controller event, of type '1' (standard mod wheel CC), AND the level exceeds the input level entered by the user, set the mod wheel event level to that of the input level.
 
That's it.  That's all it does.
 
So, I am happy to change this to try to fit whatever your needs are - I just need to better understand what exactly you need it to do.
 
As it stands now, any curve that is in place up to the max allowable level that you input is preserved, since the script does not operate on any event that has a mod wheel level value that is less than that input value.
 
Let's examine a scenario, for the last 15 events of mod wheel event data for a given midi track, so here are the levels for those 15 events, before processing the script:
 
90 91 92 93 94 95 96 97 98 99 100 101 102 103 104
 
OK, so the above is a nice smooth curve.  After processing the script, with you inputting a maximum allowable level of 98, you end up with:
 
90 91 92 93 94 95 96 97 98 98 98 98 98 98 98
 
This is per the original spec to which the script was written.
 
Please list for me how you would rather see the data look after processing, starting from the original list prior to processing.  I will cheerfully make whatever adjustments you need.
 
It almost seems like what you are looking for is a general alteration of the whole SCALE of the level, across its entire range.  If so, I am not sure how I would accomplish that, since the levels appear to only be whole number values, and a scale redefinition would seem to me to require fractional values for some of the calculated percentages.
 
Again, if you could list the level values you would like to see - using the events from the 1st set I posted above as the starting point(90-114), I can change the script to try to accommodate that.
 
Thanks, 
 
Bob Bone
 
 
 

Wisdom is a giant accumulation of "DOH!"
 
Sonar: Platinum (x64), X3 (x64) 
Audio Interfaces: AudioBox 1818VSL, Steinberg UR-22
Computers: 1) i7-2600 k, 32 GB RAM, Windows 8.1 Pro x64 & 2) AMD A-10 7850 32 GB RAM Windows 10 Pro x64
Soft Synths: NI Komplete 8 Ultimate, Arturia V Collection, many others
MIDI Controllers: M-Audio Axiom Pro 61, Keystation 88es
Settings: 24-Bit, Sample Rate 48k, ASIO Buffer Size 128, Total Round Trip Latency 9.7 ms  
#18
Jump to:
© 2025 APG vNext Commercial Version 5.1