seems like different things:
@circuitghost , angl / mangl are using supercollider GrainBuf
under the hood in a straightforward way.
upthread, i pointed out that softcut isn’t designed for “granular” processing in the sense of large polyphony, but for 2-voice polyphony it is simple: use a short loop_start / loop_end, set loop
flag to zero for one-shot mode, send pos(voice, x)
repeatedly, advancing x. you could get more polyphony by using multiple voices in round robin. but the API surely doesn’t make this very convenient.
@okyeron i think you mean an something like the scrubbing playhead in Reaper or other DAWs, which is like a jog wheel for a virtual audio tape. there exists the concept of an “edit cursor.”
i would just use the encoder to select the rate, with rate smoothing. (probably using a JI table.)
and if you wish, use the phase poll with a small quantum, to update the “edit cursor” position from the actual softcut voice phase.
(alt mode: set the cursor position independently, so by default it restarts from same pos each time; this is also a common DAW option.)
when rate specified by the rate encoder goes from zero to nonzero[^], send pos(voice, cursor)
.
(alt mode: require explicit keypress or something to restart.)
another thing that the API doesn’t really provide is the ability to just say, “stop playback now (after fadeout.)” which could be added.
[^] here is where you might want some timing logic; e.g. only restart if timeout has elapsed between encoder movements. metro
seems fine for this…