public abstract class AudioSegmenter extends UGen implements SegmentMaker
UGen.OutputInitializationRegime, UGen.OutputPauseRegime
bufferSize, bufIn, bufOut, context, ins, outputInitializationRegime, outputPauseRegime, outs
Constructor and Description |
---|
AudioSegmenter(AudioContext context)
Instantiates a new Segmenter.
|
Modifier and Type | Method and Description |
---|---|
void |
addListener(FeatureExtractor<?,float[]> fe)
Adds a FeatureExtractor as a responder to this Segmenter.
|
void |
addSegmentListener(SegmentListener sl)
Adds a SegmentListener as a listener to this Segmenter.
|
void |
removeSegmentListener(SegmentListener sl)
Removes a SegmentListerner as a listener to this Segmenter.
|
abstract void |
resetTimeStamp()
Reset both beginning and last time stamps to zero.
|
protected void |
segment(TimeStamp startTime,
TimeStamp endTime,
float[] data)
Called by instantiations of Segmenter, to indicate that a new segment has been created.
|
abstract void |
setBeginningTimeStamp(TimeStamp ts)
Set the TimeStamp of this AudioSegmenter when the AudioContext is at t=0.
|
abstract void |
setLastTimeStamp(TimeStamp ts)
Set the last TimeStamp of this AudioSegmenter.
|
java.lang.String |
toString()
Returns a String specifying the Bead's class and it's name.
|
addDependent, addInput, addInput, calculateBuffer, clearDependents, clearInputConnections, containsInput, crossfadeInput, getConnectedInputs, getContext, getEnvelopes, getIns, getNumberOfConnectedUGens, getNumberOfDependents, getOutBuffer, getOuts, getTimeTakenLastUpdate, getValue, getValue, getValueDouble, getValueDouble, initializeOuts, isTimerMode, isUpdated, noInputs, pause, printInBuffers, printInputList, printOutBuffers, removeAllConnections, removeConnection, removeDependent, setOutsToPause, setTimerMode, setValue, update, zeroIns, zeroOuts
getKillListener, getName, isDeleted, isPaused, kill, message, messageReceived, setKillListener, setName, start
public AudioSegmenter(AudioContext context)
context
- the AudioContext.public void addListener(FeatureExtractor<?,float[]> fe)
fe
- the FeatureExtractor.public void addSegmentListener(SegmentListener sl)
addSegmentListener
in interface SegmentMaker
sl
- the SegmentListener.public void removeSegmentListener(SegmentListener sl)
removeSegmentListener
in interface SegmentMaker
sl
- the SegmentListerner.protected void segment(TimeStamp startTime, TimeStamp endTime, float[] data)
startTime
- double indicating the start time of the data chunk in milliseconds.endTime
- double indicating the end time of the data chunk in milliseconds.data
- the audio data.public abstract void resetTimeStamp()
public abstract void setBeginningTimeStamp(TimeStamp ts)
ts
- public abstract void setLastTimeStamp(TimeStamp ts)
ts
-