Audio · function
driftScrapeBuffer
A skate scrape: the sound of an edge losing its bite.
Explained in Your first game.
function driftScrapeBuffer(ctx: BaseAudioContext, seconds?: number): AudioBufferimport { driftScrapeBuffer } from '@driftengine/audio';Parameters
| Parameter | Type | Description |
|---|---|---|
ctx | BaseAudioContext | |
seconds? | number |
In depth
Bright filtered noise with a slow chatter in it, so it reads as grinding rather than as hiss. The caller sweeps its playback rate with the drift's charge, which is what turns a texture into a meter you can hear — the pitch rising under you is the drift telling you how long you have held it.
Loops without a seam: the chatter completes a whole number of cycles across the buffer, and the tail crossfades into the head.