[Pipet Devel] overflow question

Jean-Marc Valin jean-marc.valin at hermes.usherb.ca
Thu Jun 22 13:47:10 EDT 2000

> ic. Why does Overflow use pulling? Nodes pushing data into the next seems more logical
> to me at first.

One word: dependencies. Here's an audio processing example: we normally divide
audio in frames of 100-500 samples. Each frame is treated separatly, but (very)
often, a node (eg. filters) needs to look at previous frames and (even) next
frames (non-causal filters). Using a pull, every node tells its inputs (by
calling getOutput) what data it needs in order to compute its result. Values
that aren't used aren't computed.

Also, there is a buffering system that keeps the last N computed results. The
number N is determined at initialization using the dependencies of each node.
This system can only be implemented using a pull. The whole system makes sure
that we only use the minimum amount of memory. 

BTW, the user shouldn't be able to tell whether we're using a pull or a push.
It's just that the pull is so much cleaner and easier to implement for more
complex processing.


Jean-Marc Valin
Universite de Sherbrooke - Genie Electrique
valj01 at gel.usherb.ca

More information about the Pipet-Devel mailing list