Skip to content

Stream from disk #2

@imprompt

Description

@imprompt

I would like to implement disk streaming capability to allow loading large instruments. Any guidance here would be very welcome to make this fit better into the existing code.

For SF2 files (to get started):

Loading an instrument:
SF2Reader::readSamples() - limit loading to first blocksize number of samples

Playing an instrument:
Something needs to trigger the reading of the full sample. I suppose this should be in sfzero::Synth::noteOn() where we could submit an asynchronous loading of the full sample into a temporary buffer. Then when sfzero::Voice::renderNextBlock() (where I understand the bulk of the rendering is done) reaches the end of it's pre-cached block, it could look at the temporary full-sample buffer.

Does this sound the best way?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions