Pitch Config
data class PitchConfig(val bufferSize: Int = 2048, val sampleRate: Int = 16000, val tolerance: Float = 0.15f, val minFreq: Float = 80.0f, val maxFreq: Float = 1000.0f, val refPitch: Float = 440.0f, val octaveWrap: Int = 0, val amplitudeGateThresholdDb: Float = -40f, val minConfidenceThreshold: Float = 0.75f)
Configuration for pitch detection (YIN algorithm).
Constructors
Properties
Link copied to clipboard
RMS amplitude threshold in dB for gating quiet frames. Frames below this threshold return unvoiced (-1). Range: -60 to -20, default -40.
Link copied to clipboard
Size of the audio buffer for analysis
Link copied to clipboard
Minimum YIN confidence (0.0-1.0) to accept pitch. Frames below this threshold return unvoiced (-1). Range: 0.5 to 0.95, default 0.75.
Link copied to clipboard
Whether to wrap octaves (0 = no, 1 = yes)
Link copied to clipboard
Audio sample rate in Hz