Can I split one input event to three output events?

From: edgar <edgar-rft_at_web.de>
Date: Tue Jan 07 2014 - 23:52:11 CET
Hi all,

The hexter DSSI plugin (Yamaha DX7 emulator):

http://dssi.sourceforge.net/hexter.html

has three frequency settings per operator: Coarse, Fine, and Detune,
which can be controlled by three NRPNs.

In order to pitch-bend a single operator (not _all_ operators like the
default hexter pitch-bend controller setting does), I need to split a
14-bit pitch-bend input event into three 14-bit NRPN output events.

The three Coarse, Fine, and Detune values (as their names say) are
not adjacent ranges, but subranges of each other:

{nrpn 81 0..16383} -> Coarse 0..31  # Overtone multiplicator
{nrpn 82 0..16383} -> Fine   0..99  # Subrange of each Coarse step
{nrpn 83 0..16383} -> Detune 0..15  # Subrange of each Fine step

This leads to a controller mapping of:

# First output event
coarse = $pitch-bend / 32
{nrpn 81 $coarse}

# Second output event
fine = ($pitch-bend - $coarse * 32) / 100
{nrpn 82 $fine}

# Third output event
detune = ($pitch-bend - $coarse * 32 - $fine * 100) / 16
{nrpn 83 $detune}

My first question is: How can I assign the 14-bit value from the
pitch-bend input event to a midish variable?

My second question is: How can I write a filter rule that sends
three output events per input event?

Or is there any other way to split a 14-bit pitch-bent event into
three NRPN events with midish?

Please excuse if the questions sound a bit stupid, but I'm still not
very experienced with writing midish filter rules, and I still was
unable to find answers to my questions in the midish manual.

Of course I do not expect that you do all the work for me, I'm already
happy if somebody can point me to the respective manual sections or
give some small code examples how this could work in general.

Thanks in advance,

- edgar
Received on Tue, 7 Jan 2014 23:52:11 +0100

This archive was generated by hypermail 2.1.8 : Wed Nov 08 2017 - 16:32:27 CET