OTTO icon indicating copy to clipboard operation
OTTO copied to clipboard

Sampler implementation

Open jmidt opened this issue 6 years ago • 1 comments

The samplers are controlled by the sequencer. Basically, this exists to play back a simple sample, with some basic editing and visualization. There are two screens, the sampler screen and the envelope screen. The envelope screen is reached by pressing the sampler button and then the envelope button. The centerpiece of the visualization is a zoom-able waveform. GFI marks a Good First Issue.

  • [ ] Sampler screen
    • [x] Filter
    • [x] Playback speed
      • [x] reverse (toggle with encoder click)
    • [ ] Sample selection
      • [x] Basic single-encoder selection
      • [ ] GFI Real menu with folders
        • [ ] Tags?
        • [ ] Select kits or select types? (808->snare vs snares->808)
    • [x] Collapse envelope to single line (with yellow/red segments) on sampler screen
      • [ ] GFI Animate this
  • [x] Envelope screen
    • [x] Begin/End, Fade-in/out
    • [x] Draw envelope under waveform like a reflection
  • [x] Waveform (for both screens)
    • [x] Draw fades. Stationary endpoints, only waveform zooms.
    • [x] Finish zoom algorithm (run build/bin/test Waveform)
    • [x] Draw waveform in top half, same position on both screens
  • [x] Change start/end point props to ints counting samples. Step by some fixed amount. Reset on sample change.
    • [x] Shift + encoder turn lower/higher resolution
  • [ ] Benchmark
    • [ ] with/without filters? Lo+Hi vs. BP?
    • [ ] Waveform view generation. start/mean/max

jmidt avatar Aug 12 '19 13:08 jmidt

Sometimes, the sampler will output NaN's or Inf's, causing ALSA to throw a fit and stop all audio output.

  • [ ] 1: Put a bit of code in the AudioManager that checks and shows an error if any frames are not valid numbers. Change frame to 0 if this happens. Should only happen on debug builds!
  • [ ] 2: Actually find the source of the bug and fix it.

jmidt avatar Aug 28 '19 11:08 jmidt