|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectbe.hogent.tarsos.sampled.pitch.AnnotationPublisher
public final class AnnotationPublisher
This class is responsible for the extraction and delegation of annotations. It notifies listeners of annotations.
Nested Class Summary | |
---|---|
static interface |
AnnotationPublisher.AnnotationFilter
FILTERS |
class |
AnnotationPublisher.PitchClassFilter
|
class |
AnnotationPublisher.SteadyStateFilter
|
Method Summary | |
---|---|
void |
addAnnotations(java.util.List<Annotation> annotations)
|
void |
addListener(AnnotationListener listener)
Adds an annotation listener. |
void |
alterSelection(double newMinProbability)
|
void |
alterSelection(double startTime,
double stopTime)
|
void |
alterSelection(double startTime,
double stopTime,
double startPitch,
double stopPitch)
|
void |
applyPitchClassFilter(double[] pitchClasses,
double maxCentsDifference)
|
void |
applySteadyStateFilter(double maxCentsDifference,
double minDuration)
|
void |
clear()
Remove all annotations from the listeners. |
void |
clearTree()
|
void |
delegateAddAnnotations(double newMinProbability)
|
void |
delegateAddAnnotations(double startTime,
double stopTime)
Adds annotations to listeners. |
void |
delegateAddAnnotations(double startTime,
double stopTime,
double startPitch,
double stopPitch)
Adds annotations to listeners. |
void |
delegateAddAnnotations(java.util.List<Annotation> annotations)
Adds a list of annotations to listeners. |
void |
extractionFinished()
|
void |
extractionStarted()
|
AnnotationTree |
getAnnotationTree()
|
java.util.List<Annotation> |
getCurrentlySelectedAnnotations()
|
AnnotationSelection |
getCurrentSelection()
|
static AnnotationPublisher |
getInstance()
|
void |
steadyStateAnnotationFilter(java.util.List<Annotation> annotations,
double maxCentsDifference,
double minDuration)
Steady state filter: only keep annotations that are repeated for x seconds within y cents. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public void addListener(AnnotationListener listener)
listener
- The listener to add.public void addAnnotations(java.util.List<Annotation> annotations)
annotations
- public void applySteadyStateFilter(double maxCentsDifference, double minDuration)
public void applyPitchClassFilter(double[] pitchClasses, double maxCentsDifference)
public void steadyStateAnnotationFilter(java.util.List<Annotation> annotations, double maxCentsDifference, double minDuration)
annotations
- The list of annotations to filter.maxCentsDifference
- The number of cents the next annotation may differ.minDuration
- The minimum duration of the 'note'.public AnnotationTree getAnnotationTree()
public void clear()
public void clearTree()
public void delegateAddAnnotations(java.util.List<Annotation> annotations)
annotations
- The annotations to add to the listeners.public void delegateAddAnnotations(double startTime, double stopTime)
startTime
- The start time.stopTime
- The stop time.public void delegateAddAnnotations(double startTime, double stopTime, double startPitch, double stopPitch)
startTime
- The start time.stopTime
- The stop time.startPitch
- The start pitch.stopPitch
- The stop pitch.public void delegateAddAnnotations(double newMinProbability)
public void alterSelection(double startTime, double stopTime, double startPitch, double stopPitch)
public void alterSelection(double startTime, double stopTime)
public void alterSelection(double newMinProbability)
public void extractionFinished()
public void extractionStarted()
public AnnotationSelection getCurrentSelection()
public java.util.List<Annotation> getCurrentlySelectedAnnotations()
public static AnnotationPublisher getInstance()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |