golib
0.5
|
3D filter class. More...
#include <gofilter3d.h>
Public Member Functions | |
goFilter3D (const goFilter3D< T_IN, T_OUT > &other) | |
const goFilter3D & | operator= (const goFilter3D< T_IN, T_OUT > &other) |
bool | setMask (const goSignal3DBase< void > &mask, bool normalize=true, goDouble factor=0.0) |
bool | setMask (const goFloat *mask, goIndex_t sizeX, goIndex_t sizeY, goIndex_t sizeZ, bool normalize=true, goDouble factor=0.0) |
void | setMaskCenter (goIndex_t x, goIndex_t y, goIndex_t z) |
goIndex_t | getMaskCenterX () const |
goIndex_t | getMaskCenterY () const |
goIndex_t | getMaskCenterZ () const |
const goSignal3D< void > & | getMask () const |
bool | filter (const goSignal3DBase< T_IN > &inSignal, goSignal3DBase< T_OUT > &outSignal) |
template<> | |
bool | filter (const goSignal3DBase< void > &inSignal, goSignal3DBase< void > &outSignal) |
Filters a signal. More... | |
![]() | |
goObjectBase () | |
Constructor. | |
virtual | ~goObjectBase () |
Destructor. More... | |
const char * | getClassName () const |
Returns the class name. More... | |
int | getClassID () const |
virtual goSize_t | memoryUsage () const |
Returns the size of this object or some measure of its memory consumption. More... | |
void | setObjectName (const char *name) |
Set name string for an object. More... | |
void | setObjectName (const goString &name) |
Set name string for an object. More... | |
const goString & | getObjectName () const |
Get the object name. More... | |
virtual bool | writeObjectFile (FILE *) const |
Write object to a file. More... | |
virtual bool | readObjectFile (FILE *) |
Read object from a file. More... | |
void | connectObject (goObjectBase *object) |
Connects an object to this object. More... | |
void | disconnectObject (const goObjectBase *object) |
Disconnects an object from this object. | |
virtual bool | callObjectMethod (int methodID, goObjectMethodParameters *param=NULL) |
Call an object method by identifier. More... | |
virtual bool | queueObjectMethod (int methodID, goObjectMethodParameters *param=NULL, bool blocking=false) |
Enqueue a method call to an internal list of methods. More... | |
bool | callQueuedMethods () |
Call all queued methods. More... | |
Additional Inherited Members | |
![]() | |
void | setClassID (int id) |
Sets the class name. | |
void | printClassMessage (const char *msg) |
Sets the class name. More... | |
void | printClassMessage (goString &msg) |
Prints an informational message to the calling console. More... | |
void | sendObjectMessage (int messageID, void *data=NULL) |
Sends a message to all connected objects. | |
void | sendObjectMessage (goObjectBase *object, int messageID, void *data=NULL) |
Sends a message to a specific object. | |
virtual void | receiveObjectMessage (const goObjectMessage &message) |
Receive a message. More... | |
3D filter class.
Applies a 3D filter to a goSignal3DBase. There is a different implementation for goFloat and goDouble input- and output-types (and vice versa) and for <void,void> template parameters. In the <void,void> case, goSignal3DBase<void> input signals can be filtered. Their use is recommended for the flexibility in data types. The filtering process is a bit slower though. The filter mask is currently always of type goFloat and must be given as a goSignal3DBase<void>. Currently, only the version for <void,void> data types has been tested. It is recommended to use goSignal3D of type <void> everywhere possible to remain more flexible. This filter class does not support separable filters by its own. Either use two or more different masks to achieve the speed gain of a separable filter, or implement another filter class.
bool goFilter3D< void, void >::filter | ( | const goSignal3DBase< void > & | inSignal, |
goSignal3DBase< void > & | outSignal | ||
) |
Filters a signal.
inSignal | The signal to be filtered, may be of any type in case it is a giSignal3DBase<void>. |
outSignal | Will contain the filtered signal after the method returned true. Must currently be of type GO_FLOAT in case of input and output types are void and must be of the same size as inSignal. |
bool goFilter3D< T_IN, T_OUT >::setMask | ( | const goSignal3DBase< void > & | mask, |
bool | normalize = true , |
||
goDouble | factor = 0.0 |
||
) |
Sets the filter mask.
mask | A goSignal3DBase containing the filter mask. Must be of data type GO_FLOAT. |
normalize | If true, the filter coefficients are normalized so that their sum equals one (default) |