Modern Apps git

← Modern-Apps.git

tuner: attach the soundingRange KDoc to soundingRange, not polyphony

Commit
1bc49b45e778d85314cf29259f8af193416c4f90
Author
Vayun Mathur <[email protected]>
When
2026-11-08 02:56 UTC (28 days ago)
Parents
05b6fca
The long KDoc block describing soundingRange (physical pitch range, fret
span, low-end absorption bound) sat directly above polyphony's own KDoc
block, so only the polyphony doc attached to its property: rendered docs
showed the sounding-range description on polyphony and left soundingRange
undocumented. Move that block down so each property carries its own doc.

Comment-only move, no behavior change. Verified with
:tuner:testDevUnitTest (BUILD SUCCESSFUL, full suite green).

Diff

tuner/src/main/java/com/vayunmathur/tuner/data/Instruments.kt
diff --git a/tuner/src/main/java/com/vayunmathur/tuner/data/Instruments.kt b/tuner/src/main/java/com/vayunmathur/tuner/data/Instruments.ktindex b8c19b1da2..bf9fef7025 100644--- a/tuner/src/main/java/com/vayunmathur/tuner/data/Instruments.kt+++ b/tuner/src/main/java/com/vayunmathur/tuner/data/Instruments.kt@@ -115,6 +115,18 @@ data class Instrument(             .filter { fretted.getOrElse(it) { MUTED_FRET } != MUTED_FRET }             .sortedBy { strings[it].openMidi + fretted[it] } +    /**+     * The most notes this instrument can sound at once.+     *+     * One per string, because a string sounds one pitch. This is the same kind of statement as+     * [soundingRange] - a fact about the instrument, not a tuning parameter - and the chord+     * pipeline uses it the same way, to discard note hypotheses outright. A ukulele producing+     * five distinct pitch classes in one frame is not a difficult chord, it is extraction+     * residue. A keyboard is bounded by the player's hands rather than by the model.+     */+    val polyphony: Int+        get() = if (strings.isEmpty()) KEYBOARD_POLYPHONY else strings.size+     /**      * Every MIDI note this instrument can physically sound: open strings up to the highest      * fretted note, or the keyboard compass.@@ -130,18 +142,6 @@ data class Instrument(      * explain it with its own partials. An [InstrumentKind.UNFRETTED] instrument has no fret      * span to bound the top, so it falls back to [analysis].      */-    /**-     * The most notes this instrument can sound at once.-     *-     * One per string, because a string sounds one pitch. This is the same kind of statement as-     * [soundingRange] - a fact about the instrument, not a tuning parameter - and the chord-     * pipeline uses it the same way, to discard note hypotheses outright. A ukulele producing-     * five distinct pitch classes in one frame is not a difficult chord, it is extraction-     * residue. A keyboard is bounded by the player's hands rather than by the model.-     */-    val polyphony: Int-        get() = if (strings.isEmpty()) KEYBOARD_POLYPHONY else strings.size-     val soundingRange: IntRange         get() = keyboard?.let { it.lowestMidi..it.highestMidi }             ?: when {