48 virtual bool isOK()
const = 0;
142 virtual bool isReady(
int *completion = 0)
const {
144 if (completion) *completion = (ok ? 100 : 0);
232 virtual void toXml(QTextStream &stream,
234 QString extraAttributes =
"")
const;
void aboutToBeDeleted()
Emitted when something notifies this model (through calling aboutToDelete() that it is about to delet...
virtual QString getMaker() const
Return the "artist" or "maker" of the model, if known.
void setRDFTypeURI(QString uri)
Set the event, feature, or signal type URI for the features contained in this model,...
static const int COMPLETION_UNKNOWN
void ready()
Emitted when internal processing is complete (i.e.
virtual int getNativeRate() const
Return the frame rate of the underlying material, if the model itself has already been resampled.
virtual int getStartFrame() const =0
Return the first audio frame spanned by the model.
AlignmentModel * m_alignment
void completionChanged()
Emitted when some internal processing has advanced a stage, but the model has not changed externally.
std::vector< float > SampleBlock
virtual const ZoomConstraint * getZoomConstraint() const
If this model imposes a zoom constraint, i.e.
void modelChangedWithin(int startFrame, int endFrame)
Emitted when a model has been edited (or more data retrieved from cache, in the case of a cached mode...
virtual QString getLocation() const
Return the location of the data in this model (e.g.
virtual bool isReady(int *completion=0) const
Return true if the model has finished loading or calculating all its data, for a model that is capabl...
void alignmentCompletionChanged()
Emitted when the completion percentage changes for the calculation of this model's alignment model.
virtual void toXml(QTextStream &stream, QString indent="", QString extraAttributes="") const
Stream this exportable object out to XML on a text stream.
virtual const AlignmentModel * getAlignment() const
Retrieve the alignment model for this model.
virtual bool isOK() const =0
Return true if the model was constructed successfully.
virtual void setSourceModel(Model *model)
Set the source model for this model.
virtual int alignFromReference(int referenceFrame) const
Return the frame number in this model that corresponds to the given frame number of the reference mod...
virtual Model * clone() const =0
Return a copy of this model.
virtual QString getTypeName() const =0
Return the type of the model.
virtual void setAlignment(AlignmentModel *alignment)
Specify an aligment between this model's timeline and that of a reference model.
void modelChanged()
Emitted when a model has been edited (or more data retrieved from cache, in the case of a cached mode...
virtual int getSampleRate() const =0
Return the frame rate in frames per second.
virtual QString toDelimitedDataStringSubset(QString, int, int) const
Model is the base class for all data models that represent any sort of data on a time scale based on ...
virtual QString toDelimitedDataString(QString delimiter) const
virtual int alignToReference(int frame) const
Return the frame number of the reference model that corresponds to the given frame number in this mod...
virtual Model * getSourceModel() const
If this model was derived from another, return the model it was derived from.
virtual int getEndFrame() const =0
Return the last audio frame spanned by the model.
virtual QString getTitle() const
Return the "work title" of the model, if known.
ZoomConstraint is a simple interface that describes a limitation on the available zoom sizes for a vi...
QString getRDFTypeURI() const
Retrieve the event, feature, or signal type URI for the features contained in this model,...
Model & operator=(const Model &)
void sourceModelAboutToBeDeleted()
virtual void abandon()
Mark the model as abandoning.
virtual const Model * getAlignmentReference() const
Return the reference model for the current alignment timeline, if any.
virtual bool isAbandoning() const
Query whether the model has been marked as abandoning.
virtual int getAlignmentCompletion() const
Return the completion percentage for the alignment model: 100 if there is no alignment model or it ha...