-
Notifications
You must be signed in to change notification settings - Fork 8
Description
Brief: smenc requires -m/-f despite its man page, invalid MIDI note causes infinite loop, and it'd benefit from automatic frequency detection.
Man Page:
The smenc man page claims that specifying the fundamental frequency via -m (MIDI note) or -f (Hz) is optional.
However, omitting these options results in an error:
$ smenc -s cymbal-1234.wav cymbal-test-%c.sm
smenc: fundamental frequency is required (can be set using -m or -f)Expected: The tool should proceed without -m/-f, using default or auto-detected values as implied by the documentation.
Actual: The tool exits with an error, enforcing -m/-f.
MIDI note input causes infinite loop:
Providing an (invalid?) MIDI note (e.g., -m e) causes smenc to hang indefinitely without error messages.
smenc -m e -s cymbal-1234.wav cymbal-test-%c.sm
<aborted after 21minutes>Expected: The tool should validate the -m argument and support strings as MIDI note or exit with an error message (e.g., "Invalid MIDI note: e").
Actual: The process runs indefinitely, consuming CPU without progress or feedback.
Feature Request: Auto-detect frequency when -m/-f are unspecified:
If -m/-f are not provided, smenc could automatically detect the fundamental frequency using a sine detection algorithm, e.g., inspired by sinedetect.cc. If detection fails, fall back to a default frequency (e.g., 440Hz).