You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently you can use sub on a SampleBuf, but you lose all the samplerate information, unitful indexing, etc.
It seems like we could tweak SampleBuf to contain any AbstractArray, and add a definition for sub that gives you a new SampleBuf that wraps the view instead of a copy. Something like
sub(buf::SampleBuf, A...) = SampleBuf(sub(buf.data), samplerate(buf)) seems like it should be pretty close.
The text was updated successfully, but these errors were encountered:
Currently you can use
sub
on aSampleBuf
, but you lose all the samplerate information, unitful indexing, etc.It seems like we could tweak
SampleBuf
to contain anyAbstractArray
, and add a definition forsub
that gives you a newSampleBuf
that wraps the view instead of a copy. Something likesub(buf::SampleBuf, A...) = SampleBuf(sub(buf.data), samplerate(buf))
seems like it should be pretty close.The text was updated successfully, but these errors were encountered: