Old 01-16-2017, 08:51 AM   #1
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,784
Default Read out curent VST Parameters

I am considering to enhance my Reaper-driven live-playing setup by a controller board that features motorfaders.

Among other gear, I use the Kontakt VSTi for sound generation.

Here, I use an instrument collection to be able to rapidly switch between multiple patches via midi Program change messages (loading a new setup takes several seconds).

Now Kontakt can "learn" midi CC control messages for allowing to modify instrument parameters in realtime. The current state of such a parameter is stored in the VST setup (for all instruments in the collection) and is restored when switching to another instrument in the collection and retuning.

So obviously all instrument parameters of all instruments in all loaded Collections in Kontakt are VST parameters.

Seemingly these parameters are updates with any incoming appropriate Midi CC message. (Saving the reaper Project saves all of them.)

Now the question is:

(How) can I (e.g. by a JSFX) read the VST parameters of a VST to send them out to the controller to have the motor faders moved after a patch change ?


Thanks for any suggestion,
-Michael
mschnell is offline   Reply With Quote
Old 01-16-2017, 11:32 AM   #2
Xenakios
Human being with feelings
 
Xenakios's Avatar
 
Join Date: Feb 2007
Location: Oulu, Finland
Posts: 8,062
Default

Quote:
Originally Posted by mschnell
So obviously all instrument parameters of all instruments in all loaded Collections in Kontakt are VST parameters.

Seemingly these parameters are updates with any incoming appropriate Midi CC message. (Saving the reaper Project saves all of them.)
The plugins don't need to have VST parameters for all their states. The VST spec allows for opaque binary data too that the host can save and load but can't manipulate or expose in any meaningful way.

Quote:
Originally Posted by mschnell

(How) can I (e.g. by a JSFX) read the VST parameters of a VST to send them out to the controller to have the motor faders moved after a patch change ?
Not possible with JSFX but the ReaScript and C++ extension API have functions like TrackFX_GetParamNormalized(MediaTrack* track, int fx, int param).
__________________
I am no longer part of the REAPER community. Please don't contact me with any REAPER-related issues.
Xenakios is offline   Reply With Quote
Old 01-16-2017, 02:25 PM   #3
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,784
Default

Quote:
Originally Posted by Xenakios View Post
The plugins don't need to have VST parameters for all their states.
AFAIK, Kontakt does not write to a file when closing. But when I change those parameters via Midi, save the Reaper project, close Reaper and restart, the changed prameters are in place. So I am rather sure that Reaper stores them via the VST params. I saw that Kontakt exports a huge count of VST Params with opaque names.

Quote:
Originally Posted by Xenakios View Post
Not possible with JSFX but the ReaScript and C++ extension API have functions like TrackFX_GetParamNormalized(MediaTrack* track, int fx, int param).
Up till now I did not do any ReaScripts, but very successfully created several JSFXes. Of course I will learn to deal with ReaScripts if appropriate.

Another option would be to route the CCs through a JSFX and and store the current values there (via hidden sliders), and react appropriately to the PC messages. (In fact I use a JSFX, anyway, to receive a configuration from SWS LiveConfigs and upon that event send a PS to Kontakt. Same could be enhanced....)

I suppose it's easier to send Midi events to the controller from a JSFX then it would be from a ReaScript.

Thanks for all infos,
-Michael

Last edited by mschnell; 01-16-2017 at 03:30 PM.
mschnell is offline   Reply With Quote
Old 01-18-2017, 02:36 PM   #4
mschnell
Human being with feelings
 
mschnell's Avatar
 
Join Date: Jun 2013
Location: Krefeld, Germany
Posts: 14,784
Default

I understand that scripts can't send out Midi messages directly from the "guts" of Reaper.

So I would either need to transfer Midi from the Script to a track, or somehow transfer the VST parameter data read by the script to a JSFX.

( As I already found out when I began to do Reaper programming, IMHO its a shame that the shared memory of the JSFXes seemingly can't be accessed by Reaper Scripts. )

As both seems rather tedious, I think I will try to store the parameter values sent from the controller to Kontakt in some JSFXes and manage the program change messages there, appropriately. Supposedly a rather clumsy method, but easily doable and quite versatile, as not tied to Kontakt in any way..

-Michael
mschnell 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 07:01 PM.


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