Support

If you have a problem or need to report a bug please email : support@dsprobotics.com

There are 3 sections to this support area:

DOWNLOADS: access to product manuals, support files and drivers

HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects

USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here

Sample Player midi problem

Post any examples or modules that you want to share here

Re: Sample Player midi problem

Postby kortezzzz » Thu Jan 14, 2021 9:52 pm

I guess this is what you're looking for?
Attachments
(OCTAVE CHANGER - MIDI STAGE).fsm
(1.03 MiB) Downloaded 63 times
User avatar
kortezzzz
 
Posts: 728
Joined: Tue Mar 19, 2013 4:21 pm

Re: Sample Player midi problem

Postby StereoSpace » Fri Jan 15, 2021 12:22 am

kortezzzz wrote:I guess this is what you're looking for?


Wow, thanks a lot, this is what I was looking for !!! no words)))
GUI designer
User avatar
StereoSpace
 
Posts: 66
Joined: Sat Feb 21, 2015 12:59 am
Location: Russia

Re: Sample Player midi problem

Postby newdsp » Fri Jan 15, 2021 1:30 am

If you look at this sampler you can detune or change octaves by changing the root key note but you can also transpose from the midi side. You can also check how the pitch bend works in Chaos. Chaos also has octave shifting and detune. The problem with the mono sampler is that it doesn't have any envelopes and if you want to add 16 or 32 envelopes or a separate envelope for each sampler it can overload the CPU. Most of them use Midi-To-Voices so I don't know which one is supposed to be different.
Attachments
WaveArp.fsm
This one works with FS 309b2. (v3.0.9b2-3319-gd51130b)
(272.57 KiB) Downloaded 56 times
MonoSampler.fsm
This one works with FS 309b2. (v3.0.9b2-3319-gd51130b)
(721.94 KiB) Downloaded 61 times
WSS.fsm
This one works with FS 309b2. (v3.0.9b2-3319-gd51130b)
(1.98 MiB) Downloaded 61 times
newdsp
 
Posts: 88
Joined: Fri Dec 11, 2020 1:57 am

Re: Sample Player midi problem

Postby newdsp » Fri Jan 15, 2021 3:27 am

Here is one octave shift done on the midi side but it needs a notes off signal because it's sustaining forever. The envelope is helping stop the sound as long as the sustain is set to zero but it still needs a notes off like in the other example.
Attachments
OctaveShift.fsm
(22.61 KiB) Downloaded 56 times
newdsp
 
Posts: 88
Joined: Fri Dec 11, 2020 1:57 am

Re: Sample Player midi problem

Postby newdsp » Fri Jan 15, 2021 3:48 am

Here is an octave shift that also has an ALL NOTES OFF included (Midi CC 123). That way all the midi notes stop if you are not holding any keys. So, it's pretty much the same thing as the OCTAVE CHANGER MIDI STAGE just done differently.
Attachments
OctaveShiftNotesOff v0.02.fsm
(26 KiB) Downloaded 60 times
OctaveShiftNotesOff.fsm
(22.89 KiB) Downloaded 57 times
newdsp
 
Posts: 88
Joined: Fri Dec 11, 2020 1:57 am

Re: Sample Player midi problem

Postby newdsp » Fri Jan 15, 2021 7:05 am

It looks like the Midi CC 123 (ALL NOTES OFF) is also completely destroying the release from the envelope. The release in the sound is always short no matter how high you set it to be on the envelope. So, it's not a very good solution so far but it's doing the octave shifting on the Midi side instead of the Poly side. The "kortezzzz" example is probably better but it's still using the Midi-To-Voices and Voices-To-Poly just like everything else.
newdsp
 
Posts: 88
Joined: Fri Dec 11, 2020 1:57 am

Re: Sample Player midi problem

Postby kortezzzz » Fri Jan 15, 2021 7:07 am

Just to clarify: The green "midi split" and "midi event" primitives (which split the midi session to green values and then re-build them) won't work after export to dll. in the DAW with anything related to bouncing or exporting to audio (from version 3.0.6 and later). This is an old bug that has been remained quite long time and continues even in the alfa versions. So avoid of using it in your played notes midi chain. Use it only to extract info, but not for playing. That's why we should prefer only Ruby midi manipulators. Ruby does work. I've also converted all my green midi manipulators to Ruby.
User avatar
kortezzzz
 
Posts: 728
Joined: Tue Mar 19, 2013 4:21 pm

Re: Sample Player midi problem

Postby newdsp » Sat Jan 16, 2021 11:20 am

I see. Well... That's pretty bad. How can I use the last note off from the second script and incorporate it in the first script ? The first script looks way more simple and elegant it just needs the note off part. Or is it it doing the note off automatically as it's received from the input ? I'm talking about this thing here:

def event i,v
m = @midiInput.to_array
shift=@a
output Midi.new m[0],m[1],m[2]+@a,m[3]
end
newdsp
 
Posts: 88
Joined: Fri Dec 11, 2020 1:57 am

Re: Sample Player midi problem

Postby kortezzzz » Sat Jan 16, 2021 1:01 pm

I'm not a Ruby guru and I hope that at least one of the gurus will answer it in details, but seems like as long as you use "m[0]" in your code, you actually get note off automatically, since "m[0]" "listens" to any change that occurs in the midi on\off session.
User avatar
kortezzzz
 
Posts: 728
Joined: Tue Mar 19, 2013 4:21 pm

Re: Sample Player midi problem

Postby trogluddite » Sat Jan 16, 2021 3:49 pm

Your Ruby code does also handle the note-offs. In fact, it shifts all MIDI messages, which could be a problem, as it will also offset pitch-bend messages and change the index of controller messages. There's also a chance that the code will cause errors when the shift amount is changed (it might call "event" without a MIDI object to handle).

The following code will be more reliable (assuming that @a is your shift amount)...
Code: Select all
def event i, v
  # Exit if the incoming value is not a MIDI message.
  return unless v.is_a?(Midi)

  # Shift the note value only for note-on, note-off, and note-AT messages.
  v.data1 += @a if v.status <= 160

  # Send to output.
  output v
end
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1706
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

PreviousNext

Return to User Examples

Who is online

Users browsing this forum: Google [Bot] and 9 guests