Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

AttackOffset

File: Rhapsodist/Processors/AttackOffset.js.

Overview

Applies a randomised sample start offset and volume fade-in. Scaled separately for a note’s initial attack versus a rapid repetition of the same note (within 0.2s), and further scaled by velocity between MinVelocity and MaxVelocity.

A repetition never scales below half its maximum offset/fade; a fresh attack can scale all the way to zero at the highest tracked velocity.

Parameters

IDDescription
MuteDisables the processor; no offset or fade is applied while on.
AttackOffsetMax sample start offset for a fresh attack, -1–20000 samples.
RepeatOffsetMax sample start offset for a repeated attack, -1–20000 samples.
AttackFadeMax fade-in time for a fresh attack, 0–500 ms.
RepeatFadeMax fade-in time for a repeated attack, 0–500 ms.
MinVelocity / MaxVelocityVelocity range (0–127) over which offset/fade are scaled by velocity.

-1 on an offset knob tells HISE to use the sample’s own configured Sample Start Offset, so these knobs only matter on samples that have one set.

Usage

Load into a sampler’s MIDI Processor chain and set the knobs to taste.

Internal Reference

FunctionDescriptionReturns
getScaledValue(maxValue: number, velocity: number, minValue: number)Scales maxValue by velocity position between MinVelocity/MaxVelocity, floored at minValue as a fraction of maxValue, then applies +/-10% random jitter. Returns maxValue unchanged if it’s -1.number