8000 ResidentSf2Synth: Bad noteOn/noteOff responses · Issue #31 · notator/WebMIDISynthHost · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on May 2, 2022. It is now read-only.
This repository was archived by the owner on May 2, 2022. It is now read-only.
ResidentSf2Synth: Bad noteOn/noteOff responses #31
Open
@notator

Description

@notator

From WebMIDISynthHost issue #6:

  1. Start the WebMIDISynthHost application,
  2. Select the ResidentSf2Synth synthesizer
  3. Using the default "grand piano" preset, send the default noteOn.

There is a delay before the synth responds to the first noteOn. Why?

Even when the noteOn is reponding correctly, the noteOff does not respond immediately if it comes too soon. Why?
.................

I've now solved both these issues, but have been unable to discover why the first noteOn is delayed, and my solution to the noteOff problem is also not entirely satisfactory.

My kludge for the delayed NoteOn problem is as follows:
When the first soundfont has loaded:

  1. set the first synth's master volume to 0.
  2. set its soundFont to the first soundFont
  3. send a dummy noteOn/noteOff pair
  4. after ca.2 seconds, reset the master volume and tell the host that the font has loaded.
    Not nice, but it works. I think there may be an uninitialized buffer somewhere, but have been unable to find it...

NoteOffs now end the sound much earlier.
In the original gree code, notes stop sounding instrument.volRelease seconds after the noteOff arrives.
In the Arachno font, instrument.volRelease is 3.08 in preset 0 (grand piano).
It cannot be the case that a piano note only stops 3.08 seconds after a noteOff arrives. Multiplying the instrument's volRelease and modRelease attributes by 0.1 sounds much more realistic...
This is probably not the correct, official solution, but it produces acceptable behaviour for all the presets I've tried. Anyone know what that correct solution is?

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0