mic sensitivity setting

This commit is contained in:
2025-12-27 18:43:19 +01:00
parent 2ad1fe0ea9
commit 03a5e8e3c1
5 changed files with 68 additions and 5 deletions

View File

@@ -26,7 +26,6 @@ const NOTE_MATCH_THRESHOLD_MS = 300; // How long to convert hold note to confirm
function App() {
const [listening, setListening] = useState(false);
const { pitchData, error } = usePitchDetector(listening);
const { playNote } = useAudioPlayer();
const [targetMidi, setTargetMidi] = useState<number>(60); // Start with C4
@@ -55,9 +54,12 @@ function App() {
autoPlayVolume: 0.5,
virtualGuitarVolume: 0.5,
virtualGuitarMute: false,
micSensitivity: 0.5,
disableAnimation: false
});
const { pitchData, error } = usePitchDetector(listening, settings.micSensitivity);
const [matchStartTime, setMatchStartTime] = useState<number | null>(null);
const [feedbackMessage, setFeedbackMessage] = useState<string>("");
const [revealed, setRevealed] = useState(false);