ferraus fade
Fade in and/or out
Synopsis
ferraus fade <input> [options] [-o <output>]
What it does
Fades are computed in gain, not dB, so 'linear' is a straight amplitude ramp. 'log' changes the level evenly in dB (60 dB range), which matches the ear's loudness curve and is the recommended choice for musical fades; 'exp' is its mirror (fast start), 'scurve' eases in and out, and 'equal-power' (sine) suits crossfades. With --in 0s and --out 0s the input is returned unchanged.
This command is also an fx stage and a pipeline op: ferraus fx in.wav -o out.wav --fx "fade:key=value".
Examples
Musical fade in and out
ferraus fade song.wav --in 2s --out 4s --curve log -o faded.wav
Fade to silence one second before the end
ferraus fade take.wav --out 500ms --out-end -1s -o cut.wav
One-beat fade-in at 120 BPM
ferraus fade loop.wav --in 1b --bpm 120 -o loop_in.wav
Options
| Flag | Type | Default | Meaning |
|---|---|---|---|
--in | time | 0s | Fade-in length (seconds, ms, beats, or mm:ss) |
--out | time | 0s | Fade-out length |
--curve | linear | log | exp | scurve | equal-power | linear | Fade shape (gain curve) |
--in-start | time | start | Where the fade-in begins; audio before it is silenced |
--out-end | time | end | Where the fade-out reaches silence (e.g. -2s = two seconds before the end); audio after it is silenced |
--mix | percent | 100% | Dry/wet balance: 0% returns the input unchanged, 100% is fully processed |
Global options
Every command also accepts the global options (-o, --json, --dry-run, --overwrite, --progress, ...). See Global options.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | Processing failed |
| 2 | Usage or parameter error |
| 3 | Input missing or unreadable |
| 4 | Unsupported format or codec |
| 8 | Cancelled |
| 70 | Internal error (bug) |
Common mistakes
- Forgetting that outputs are never overwritten: pass
--overwriteor a new-opath when re-running. - Beat-based times (
4b,1/4) need a tempo: pass--bpmor write4b@120.
For models
- MCP tool:
ferraus_fade - Schema:
ferraus schema fade - Pipeline:
{ op: fade, args: { ... } }(flag names with_instead of-) - fx stage: yes
{"command": "fade", "defaults": {"in": "0s", "out": "0s", "curve": "linear", "in_start": "start", "out_end": "end", "mix": "100%"}}