soundscrape

A programmatic framework for modular synthesis:
Scheme in the front, C in the back!
< | ^ | > | :>

Overview

There are two fundamental modes of operation for Spawn: sample-accurate and buffer-synchronized.

Sample-accurate operation

The problem is that we will probably be in the middle of a buffer when a new event is spawned. The sub-network will still be operating at the same buffer-frames, but offset by a constant value. So for each pad, we need to store (1) the offset of the sub-network and (2) a pointer to the buffer containing leftover data. Furthermore, as in general there will be more than one SSSpawnAdder in a spawn element, there needs to be a scheme-accessible way to make these pads and add them to the element.

The solution will be to make a custom pad class, exposing the offset as a property. The element will then be added to the element via gst-element-add-pad. The spawn-adder will not be explicitly notified of the new event, and won't listen to the "new-pad" signal; instead it must loop through its pads on each iteration.

Buffer-synchronised operation

This mode of operation is a bit easier, as well as more efficient. If there is to be a new event within the buffer, it will start at the beginning of the buffer. Thus the two networks will operate at the same buffer-frames with zero relative offset.

The spawner can be set to one mode or the other via an object property on the spawn-adder.

Usage

< | ^ | > | :>