16 #ifndef _DENSE_THREE_DIMENSIONAL_MODEL_H_ 17 #define _DENSE_THREE_DIMENSIONAL_MODEL_H_ 77 virtual float getValueAt(
int column,
int n)
const = 0;
116 if (y > 0 && value <
getValueAt(x, y - 1))
return false;
146 case 0:
return tr(
"Time");
147 case 1:
return tr(
"Frame");
152 virtual QVariant
getData(
int row,
int column,
int)
const 158 return rt.
toText().c_str();
virtual int getWidth() const =0
Return the number of columns of bins in the model.
virtual int getCompletion() const =0
virtual QString getBinValueUnit() const
Obtain the name of the unit of the values returned from getBinValue(), if any.
virtual QString getHeading(int column) const
static RealTime frame2RealTime(long frame, unsigned int sampleRate)
Convert a sample frame at the given sample rate into a RealTime.
std::string toText(bool fixedDp=false) const
Return a user-readable string to the nearest millisecond, in a form like HH:MM:SS....
virtual float getValueAt(int column, int n) const =0
Get the single data point from the n'th bin of the given column.
virtual QVariant getData(int row, int column, int) const
virtual bool shouldUseLogValueScale() const =0
Estimate whether a logarithmic scale might be appropriate for the value scale.
bool isLocalPeak(int x, int y)
Utility function to query whether a given bin is greater than its (vertical) neighbours.
virtual bool isColumnTimeValue(int col) const
virtual long getFrameForRow(int row) const
virtual float getMinimumLevel() const =0
Return the minimum permissible value in each bin.
virtual int getRowCount() const
virtual bool hasBinValues() const
Return true if the bins have values as well as names.
QString getTypeName() const
Return the type of the model.
DenseThreeDimensionalModel()
bool isOverThreshold(int x, int y, float threshold)
Utility function to query whether a given bin is greater than a certain threshold.
virtual int getResolution() const =0
Return the number of sample frames covered by each column of bins.
virtual int getSampleRate() const =0
Return the frame rate in frames per second.
Model is the base class for all data models that represent any sort of data on a time scale based on ...
TabularModel is an abstract base class for models that support direct access to data in a tabular for...
virtual Column getColumn(int column) const =0
Get data from the given column of bin values.
virtual SortType getSortType(int) const
virtual float getBinValue(int n) const
Return the value of bin n, if any.
virtual QString getBinName(int n) const =0
Get the name of a given bin (i.e.
virtual int getRowForFrame(long frame) const
virtual int getColumnCount() const
virtual float getMaximumLevel() const =0
Return the maximum permissible value in each bin.
virtual int getHeight() const =0
Return the number of bins in each column.
virtual bool isColumnAvailable(int column) const =0
Return true if there are data available for the given column.
RealTime represents time values to nanosecond precision with accurate arithmetic and frame-rate conve...