|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.softsynth.jsyn.util.VoiceAllocator com.softsynth.jmsl.jsyn.BussedVoiceAllocatorMultiOut
public abstract class BussedVoiceAllocatorMultiOut
JSyn VoiceAllocator for SynthNotes whose output has one or more parts. It creates a BusReader for each part of SynthNote.output. setNumOutputs() then buildReaders() Subclasses must implement makeVoice() and addVoiceToMix()
BVAClassName
Constructor Summary | |
---|---|
BussedVoiceAllocatorMultiOut(int numVoices)
constructor with null synthcontext. |
|
BussedVoiceAllocatorMultiOut(int numVoices,
com.softsynth.jsyn.SynthContext synthContext)
|
Method Summary | |
---|---|
com.softsynth.jsyn.BusWriter |
addBusWriter()
|
com.softsynth.jsyn.SynthCircuit |
addVoiceToMix(com.softsynth.jsyn.SynthCircuit circuit)
for (int i = 0; i < getNumOutputs(); i++) { BusWriter busWriter = addBusWriter(); BusWriter busWriter = addBusWriter(); if (circuit instanceof OutputProvider) { ((SynthOutput) ((OutputProvider) circuit).getOutput(i)).connect(0, busWriter.input, 0); } else { circuit.output.connect(i, busWriter.input, 0); } connectBusWriterToBusReader(busWriter, i); } return circuit; |
void |
buildReaders()
Call after setNumOutputs() |
void |
connectBusWriterToBusReader(com.softsynth.jsyn.BusWriter busWriter,
int readerIndex)
|
com.softsynth.jsyn.BusReader |
getBusReader(int n)
|
int |
getNumOutputs()
|
com.softsynth.jsyn.SynthOutput |
getOutput()
|
com.softsynth.jsyn.SynthOutput |
getOutput(int part)
|
com.softsynth.jsyn.SynthContext |
getSynthContext()
|
void |
setNumOutputs(int n)
Call buildReaders() after this |
void |
setSynthContext(com.softsynth.jsyn.SynthContext context)
|
void |
start()
|
void |
start(int time)
|
void |
stop()
|
void |
stop(int time)
|
Methods inherited from class com.softsynth.jsyn.util.VoiceAllocator |
---|
allocate, allocate, allocate, allocate, clear, delete, free, free, getMaxVoices, getNthVoice, getNumVoices, makeVoice, steal, steal, steal, steal |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BussedVoiceAllocatorMultiOut(int numVoices) throws com.softsynth.jsyn.SynthException
com.softsynth.jsyn.SynthException
public BussedVoiceAllocatorMultiOut(int numVoices, com.softsynth.jsyn.SynthContext synthContext) throws com.softsynth.jsyn.SynthException
com.softsynth.jsyn.SynthException
Method Detail |
---|
public int getNumOutputs()
public void setNumOutputs(int n)
public void start()
public void start(int time)
public void stop()
stop
in class com.softsynth.jsyn.util.VoiceAllocator
public void stop(int time)
stop
in class com.softsynth.jsyn.util.VoiceAllocator
public void buildReaders()
public com.softsynth.jsyn.BusWriter addBusWriter()
public com.softsynth.jsyn.BusReader getBusReader(int n)
public void connectBusWriterToBusReader(com.softsynth.jsyn.BusWriter busWriter, int readerIndex)
public com.softsynth.jsyn.SynthOutput getOutput()
public com.softsynth.jsyn.SynthOutput getOutput(int part)
public com.softsynth.jsyn.SynthCircuit addVoiceToMix(com.softsynth.jsyn.SynthCircuit circuit) throws com.softsynth.jsyn.SynthException
for (int i = 0; i < getNumOutputs(); i++) { BusWriter busWriter = addBusWriter(); BusWriter busWriter = addBusWriter(); if (circuit instanceof OutputProvider) { ((SynthOutput) ((OutputProvider) circuit).getOutput(i)).connect(0, busWriter.input, 0); } else { circuit.output.connect(i, busWriter.input, 0); } connectBusWriterToBusReader(busWriter, i); } return circuit;
circuit
-
com.softsynth.jsyn.SynthException
public com.softsynth.jsyn.SynthContext getSynthContext()
public void setSynthContext(com.softsynth.jsyn.SynthContext context)
context
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |