21 #ifndef VESPUCCIWORKSPACE_H 23 #define VESPUCCIWORKSPACE_H 53 void AddDataset(QSharedPointer<VespucciDataset> dataset);
59 QSharedPointer<VespucciDataset>
DatasetAt(
const QModelIndex &parent);
74 QSharedPointer<VespucciDataset>
GetDataset(
const QString &key)
const;
75 QSharedPointer<AnalysisResults>
GetAnalysisResults(
const QString &dataset_key,
const QString &results_key)
const;
76 QSharedPointer<MapData>
GetMap(
const QString &dataset_key,
const QString &map_key)
const;
77 QSharedPointer<MapData>
GetMap(
const QStringList &map_keys);
78 const mat &
GetAuxiliaryMatrix(
const QString &dataset_key,
const QString &matrix_key)
const;
79 const mat &
GetResultsMatrix(
const QString &dataset_key,
const QString &results_key,
const QString &matrix_key)
const;
80 const mat &
GetCoreMatrix(
const QString &dataset_key,
const QString &matrix_key)
const;
87 void AddGlobalGradient(QString name, QString gradient_key,
double lower,
double upper);
99 QList<QSharedPointer<VespucciDataset> > *
datasets();
110 const mat &
GetMatrix(
const QStringList &keys)
const;
111 bool HasMatrix(
const QStringList &keys)
const;
113 bool Mappable(
const QStringList &keys)
const;
114 bool Plottable(
const QStringList &keys)
const;
118 void UpdateTreeModel();
141 unsigned int dataset_loading_count_;
163 QMap<QString, QCPColorGradient> gradients_;
164 QMap<QString, Vespucci::GlobalGradient> global_gradients_;
167 #endif // VESPUCCIWORKSPACE_H void RemoveDatasetAt(const QModelIndex &parent)
VespucciWorkspace::RemoveDatasetAt.
bool Plottable(const QStringList &keys) const
void set_directory(QString directory)
VespucciWorkspace::set_directory.
QSharedPointer< VespucciDataset > GetDataset(const QString &key) const
VespucciWorkspace::GetDataset.
QStringList dataset_names() const
void ClearDatasets()
VespucciWorkspace::ClearDatasets Clears the internal container for datasets in the list model...
unsigned int UpdateCount()
VespucciWorkspace::UpdateCount.
void AddDataset(QSharedPointer< VespucciDataset > dataset)
VespucciWorkspace::AddDataset.
Vespucci::GlobalGradient GetGlobalGradient(QString key)
bool Mappable(const QStringList &keys) const
const mat & GetCoreMatrix(const QString &dataset_key, const QString &matrix_key) const
The VespucciDataset class This is the main class for dealing with hyperspectral data. This handles the import and export of spectra, and the creation of maps. Images are handled by the MapData class. This class is intended to be allocated on the heap inside of a smart pointer, there is no copy constructor.
const mat & GetMatrix(const QStringList &keys) const
VespucciWorkspace::GetMatrix.
MainWindow * main_window()
VespucciWorkspace::main_window.
QSharedPointer< VespucciDataset > DatasetAt(const QModelIndex &parent)
void RemoveDataset(QString name)
VespucciWorkspace::RemoveDataset.
The VespucciWorkspace class A class which contains all "global variables" (that aren't held in MainWi...
QStringList GlobalGradientKeys()
QString * directory_ptr()
VespucciWorkspace::directory_ptr.
QCPRange * global_data_range()
VespucciWorkspace::global_data_range.
QMap< QString, Vespucci::GlobalGradient > global_gradients()
int dataset_loading_count() const
VespucciWorkspace::dataset_loading_count.
QStringList GradientNames(bool include_cluster=false)
void SetPointers(MainWindow *main_window, DatasetTreeModel *tree_model)
VespucciWorkspace::SetPointers.
QList< QSharedPointer< VespucciDataset > > * datasets()
void AddGlobalGradient(QString name, QString gradient_key, double lower, double upper)
VespucciWorkspace::AddGlobalGradient.
const mat & GetResultsMatrix(const QString &dataset_key, const QString &results_key, const QString &matrix_key) const
double GetWavelengthMax(const QString &key) const
VespucciWorkspace::GetWavelengthMax.
void RemoveColorRange(QString name)
VespucciWorkspace::RemoveColorRange.
QSharedPointer< AnalysisResults > GetAnalysisResults(const QString &dataset_key, const QString &results_key) const
VespucciWorkspace::GetAnalysisResults.
QCPColorGradient * global_gradient()
VespucciWorkspace::global_gradient.
double GetWavelengthMin(const QString &key) const
VespucciWorkspace::GetWavelengthMin.
bool HasMatrix(const QStringList &keys) const
VespucciWorkspace(QString settings_file)
VespucciWorkspace::VespucciWorkspace Constructor.
QCPColorGradient GetGradient(QString key, int count=0)
QSharedPointer< MapData > GetMap(const QString &dataset_key, const QString &map_key) const
void UpdateModel()
VespucciWorkspace::UpdateModel Call when a VespucciDataset adds or removes a new object.
Defines a color gradient for use with e.g. QCPColorMap.
QString directory() const
VespucciWorkspace::directory.
Represents the range an axis is encompassing.
The MainWindow class The main window of the program, this is where the user performs most operations...
The AnalysisResults class A container for a mat object that allows a mat to be copied to a heap-alloc...
~VespucciWorkspace()
VespucciWorkspace::~VespucciWorkspace Destructor.
void RecalculateGlobalGradient(QString name)
DatasetTreeModel * dataset_tree_model() const
dataset_list_model
const mat & GetAuxiliaryMatrix(const QString &dataset_key, const QString &matrix_key) const