From b45a21976bece19da81166324dc1cc4260a0e0f4 Mon Sep 17 00:00:00 2001 From: Samuel Fadel Date: Wed, 10 Feb 2016 18:31:48 -0200 Subject: Added ProjectionHistory object for history tracking. --- projectionobserver.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'projectionobserver.h') diff --git a/projectionobserver.h b/projectionobserver.h index 6d8b0f9..11338f5 100644 --- a/projectionobserver.h +++ b/projectionobserver.h @@ -4,6 +4,8 @@ #include #include +#include "projectionhistory.h" + class ProjectionObserver : public QObject { @@ -13,7 +15,9 @@ public: static const int OBSERVER_DIFF_PREVIOUS = 1; static const int OBSERVER_DIFF_ORIGINAL = 2; - ProjectionObserver(const arma::mat &X, const arma::uvec &cpIndices); + ProjectionObserver(const arma::mat &X, + const arma::uvec &cpIndices, + ProjectionHistory *history); signals: void valuesChanged(const arma::vec &values) const; @@ -34,7 +38,7 @@ private: bool emitValuesChanged() const; int m_type; - arma::mat m_X, m_Y, m_firstY, m_prevY; + arma::mat m_X; arma::mat m_distX, m_distY, m_firstDistY, m_prevDistY; arma::uvec m_cpIndices, m_rpIndices; @@ -47,7 +51,7 @@ private: // TODO: one per implemented measure arma::vec m_values, m_firstValues, m_prevValues; - bool m_hasFirst, m_hasPrev; + ProjectionHistory *m_history; }; #endif // PROJECTIONOBSERVER_H -- cgit v1.2.3