sf2 default modulators

Started by rv,

rv

hello,
I want a confirmation with the note on velocity to attenuation modulator
Do we need to first disable the default modulator, then add a second one to set the new value?

This may be as explained in the chapter 8.4 of the spec

8.4 Default Modulators
The "default" modulators are described below. These modulator values are the default for the instrument level; IE they are
not default at the preset level. The default modulators at the preset level are such that there is no additional control over any
parameter.
Note that these modulators are implicit to the file format, so in order to turn them off one must explicitly put modulators in
the appropriate level of the hierarchy to either supersede or negate the effect of these modulators.

Please review section 9.4, the SoundFont Modulator Controller Model Theory of Operations for a detailed description of
the general nature of these modulators, as well as the effect of Modulators upon default modulators in different levels in the
SoundFont hierarchy.

However, this is only needed to tur them off. But in the chapter 9.5.1 they explain the things in details :

A modulator, contained within a global instrument zone, that is identical to a default modulator supersedes or
replaces the default modulator.

• A modulator in a global instrument zone with the same destination but different source or transform parameters
has its effects added to the destination.
• A modulator, that is contained in a local instrument zone, which is identical to a default modulator or to a
modulator in a global instrument zone supersedes or replaces that modulator.

• A modulator in a local instrument zone with the same destination but different source or transform parameters
has its effects added to the destination.
• A modulator at the preset level adds to a modulator at the instrument level if both modulators are identical.
Otherwise, the effects of a modulator at the preset level are added to the effects of a modulator at the instrument
level.
• A modulator, contained within a global preset zone, that is identical to a default modulator or to a modulator in
an instrument adds to that modulator.

• A modulator in a global preset zone in an preset which is not identical to a default modulator and is not identical
to a modulator in an instrument has its effect added to the given destination.
• A modulator, contained within a local preset zone, that is identical to a modulator in a global preset zone
supersedes or replaces that modulator in the global preset zone. That modulator then has its effects added to the
destination summing node of all zones in the given instrument.
• A modulator in a local preset zone which is not identical to a default modulator or a modulator in a global preset
zone has its effects added to the destination summing node of all zones in the given instrument.


rv

By the way, what is your default value for the note on velocity to attenuation modulator ?

Ian @ un4seen

BASSMIDI's default "note on velocity to attenuation" modulator is as defined in the SF2 spec (eg. amount=960). If you want to use a totally different modulator (eg. different curve) then you would also need to disable the default modulator by setting its amount to 0. But if you just want to change the default modulator's amount then you can do that without disabling it first.

Zenxia

The velocity to attenuation currently it's supported, i mean that you asking about velocity to CC#7 thats modify the volume curve (cc#7).

By default the SF2 standard uses concave curve