Repository navigation
Add ConvolutionFilter and High/Low DSP filter types - #319
Merged
Merged
Conversation
Adds a convolution (impulse response) filter, following the existing filter models. It carries an ir_id referencing a server-stored impulse response file and a gain output trim in dB, validated -60 to 60 the same as GainFilter. The server resolves ir_id to a file at playback time; this model only carries the reference and the trim. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01AUR7Pf5Kusno8MSfT2Fgod
Adds a high-pass / low-pass filter with a mode toggle, cutoff frequency, and selectable 12/24/48 dB/octave slope. Validation enforces a 20-20000 Hz cutoff and the discrete slope set. Registered on DSPFilterType and the DSPFilter union, with construction, validation, and round-trip tests.
Only 12, 24 and 48 dB/octave are allowed, so model them as a HighLowPassSlope IntEnum instead of a plain int. The wire format is unchanged (still a bare int), and the exact type check in validate() now also rejects floats, which mashumaro would otherwise serialize back out as floats. Co-Authored-By: Claude Opus 4.8 <[email protected]> Claude-Session: https://claude.ai/code/session_01K2FbbLYP9Ex32Z7gsEZpWc
maximmaxim345
approved these changes
Jul 23, 2026
maximmaxim345
left a comment
Member
There was a problem hiding this comment.
Looks good!
Thanks @OzGav !
github-actions Bot
pushed a commit
to music-assistant/server
that referenced
this pull request
Jul 23, 2026
Update music-assistant-models to version [1.1.169](https://github.com/music-assistant/models/releases/tag/1.1.169) - Add setup flow primitives (by @marcelveldt in [#324](music-assistant/models#324)) ## 🚀 Features and enhancements - Add ConvolutionFilter and High/Low DSP filter types (by @OzGav in [#319](music-assistant/models#319)) ## 🙇 Contributors @marcelveldt, @OzGav and @claude Co-authored-by: marcelveldt <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds two new filter types following the existing filter models
The convolution (impulse response) filter carries an
ir_idreferencing a server-stored impulse response file and a gain output trim in dB, validated -60 to 60 the same asGainFilter. The server resolvesir_idto a file at playback time; this model only carries the reference and the trim.The high-pass / low-pass filter carries a mode toggle (high_pass or low_pass), a cutoff frequency in Hz, and a slope in dB/octave, validated to 20–20000 Hz with slope restricted to 12, 24, or 48. A single type covers both directions via the mode field. Resonance/Q is intentionally omitted that's what the Parametric EQ is for; the server derives per-stage Butterworth Q from the slope and cascades biquads to realise the steeper rolloffs. This model only carries the cutoff, direction, and slope.