ALBA
albaMatrixPipe.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: ALBA (Agile Library for Biomedical Applications)
4 Module: albaMatrixPipe
5 Authors: Marco Petrone
6
7 Copyright (c) BIC
8 All rights reserved. See Copyright.txt or
9
10
11 This software is distributed WITHOUT ANY WARRANTY; without even
12 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
13 PURPOSE. See the above copyright notice for more information.
14
15=========================================================================*/
16#ifndef __albaMatrixPipe_h
17#define __albaMatrixPipe_h
18//----------------------------------------------------------------------------
19// includes :
20//----------------------------------------------------------------------------
21#include "albaTransformBase.h"
22#include "albaTimeStamped.h"
23//----------------------------------------------------------------------------
24// forward declarations :
25//----------------------------------------------------------------------------
26class albaVME;
27
38class ALBA_EXPORT albaMatrixPipe: public albaTransformBase
39{
40public:
42 virtual ~albaMatrixPipe();
43
45
46 void UpdateMatrixObserverOn() {m_UpdateMatrixObserverFlag=1;}
47 void UpdateMatrixObserverOff() {m_UpdateMatrixObserverFlag=0;}
48 void SetUpdateMatrixObserverFlag(bool flag) {m_UpdateMatrixObserverFlag=flag;}
49 bool GetUpdateMatrixObserverFlag() {return m_UpdateMatrixObserverFlag;}
50
52 int SetVME(albaVME *vme);
54 albaVME *GetVME() {return m_VME;}
55
57 virtual void SetTimeStamp(albaTimeStamp t);
58
61
63 virtual unsigned long GetMTime();
64
66 virtual bool Accept(albaVME *vme) {return true;}
67
69 virtual const albaMatrix &GetMatrix();
70
77
81 virtual int DeepCopy(albaMatrixPipe *pipe);
82
86 virtual void Update();
87
88protected:
90 virtual void InternalUpdate();
91
95
96private:
97 albaMatrixPipe(const albaMatrixPipe&); // Not implemented
98 void operator=(const albaMatrixPipe&); // Not implemented
99
100};
101
102#endif /* __albaMatrixPipe_h */
103
double albaTimeStamp
type for time varying data timestamps (not for pipelines timestamps!)
Definition: albaDefines.h:57
bridge class between albaTransform pipeline and VME to compute VME output matrix.
bool m_UpdateMatrixObserverFlag
int SetVME(albaVME *vme)
set the VME connected to this class.
albaVME * m_VME
pointer to VME
virtual const albaMatrix & GetMatrix()
Redefined to avoid loops while updating.
virtual void Update()
Redefined to send pre update event to the VME.
virtual unsigned long GetMTime()
Get the MTime: this is the bit of magic that makes everything work.
void UpdateMatrixObserverOff()
albaTimeStamp GetTimeStamp()
return the time stamp currently set to the pipe
virtual void SetTimeStamp(albaTimeStamp t)
Set the current time.
virtual int DeepCopy(albaMatrixPipe *pipe)
Copy from another pipe, the function return ALBA_ERROR if the specied pipe is not compatible.
virtual void InternalUpdate()
To be redefined by subclasses to override Pipe behavior.
albaTypeMacro(albaMatrixPipe, albaTransformBase)
void SetUpdateMatrixObserverFlag(bool flag)
virtual bool Accept(albaVME *vme)
This function returns true if given VME is accepted by this Pipe.
albaMatrixPipe * MakeACopy()
Make a copy of this pipe, also copying all parameters.
bool GetUpdateMatrixObserverFlag()
void UpdateMatrixObserverOn()
virtual ~albaMatrixPipe()
albaVME * GetVME()
return the VME this matrix pipe is connected to
albaMatrix - Time stamped 4x4 Matrix.
Definition: albaMatrix.h:44
Superclass for Homogeneous transformations.
albaVME -
Definition: albaVME.h:150