RAVE
|
Interface for defining your own compositing algorithm. More...
#include "rave_object.h"
#include "rave_types.h"
#include "raveobject_list.h"
#include "rave_field.h"
Go to the source code of this file.
Classes | |
struct | _CompositeAlgorithm_t |
The basic composite algorithm that can be cast into a subclassed processor. More... | |
Macros | |
#define | COMPOSITE_ALGORITHM_HEAD |
The head part for a CompositeAlgorithm subclass. | |
#define | CompositeAlgorithm_getName(self) |
Macro expansion for calling the name function. | |
#define | CompositeAlgorithm_reset(self, x, y) |
Macro expansion for calling the process function. | |
#define | CompositeAlgorithm_supportsProcess(self) |
Macro expansion if this algorithm supports process or not. | |
#define | CompositeAlgorithm_process(self, obj, quantity, olon, olat, dist, otype, ovalue, navinfo) |
Macro expansion for calling the process function. | |
#define | CompositeAlgorithm_initialize(self, objects) |
Macro expansion for initializing the algorithm. | |
#define | CompositeAlgorithm_supportsFillQualityInformation(self, howtask) |
Macro expansion if this algorithm supports process or not. | |
#define | CompositeAlgorithm_fillQualityInformation(self, obj, howtask, quantity, field, x, y, navinfo, gain, offset) |
Macro expansion if this algorithm supports process or not. | |
Typedefs | |
typedef const char *(* | composite_algorithm_getName_fun) (struct _CompositeAlgorithm_t *self) |
typedef void(* | composite_algorithm_reset_fun) (struct _CompositeAlgorithm_t *self, int x, int y) |
The resetting mechanism that will be called for each new x/y position in the composite. | |
typedef int(* | composite_algorithm_supportsProcess_fun) (struct _CompositeAlgorithm_t *self) |
The supports process function that indicates if process is supported or not. | |
typedef int(* | composite_algorithm_processor_fun) (struct _CompositeAlgorithm_t *self, RaveCoreObject *obj, const char *quantity, double olon, double olat, double dist, RaveValueType *otype, double *ovalue, PolarNavigationInfo *navinfo) |
The processor function definition. | |
typedef int(* | composite_algorithm_initialize_fun) (struct _CompositeAlgorithm_t *self, struct _Composite_t *composite) |
The initializing function so that we know what composite we are working with. | |
typedef int(* | composite_algorithm_supportsFillQualityInformation_fun) (struct _CompositeAlgorithm_t *self, const char *howtask) |
Function to be used when querying if this algorithm supports the quality field with how/task value. | |
typedef int(* | composite_algorithm_fillQualityInformation_fun) (struct _CompositeAlgorithm_t *self, RaveCoreObject *obj, const char *howtask, const char *quantity, RaveField_t *field, long x, long y, PolarNavigationInfo *navinfo, double gain, double offset) |
Function to be used when filling quality information into a rave field at pos x,y-. | |
typedef struct _CompositeAlgorithm_t | CompositeAlgorithm_t |
The basic composite algorithm that can be cast into a subclassed processor. | |
Interface for defining your own compositing algorithm.
This object type is used when you need to define your own way of determining if a composite value should be set or not. It is also quite strict when it comes to how to handle the method invocations. When the Composite_nearest or similar is started, the method CompositeAlgorithm_initialize will be called. Then, for each value calculated CompositeAlgorithm_process will be called.
#define COMPOSITE_ALGORITHM_HEAD |
The head part for a CompositeAlgorithm subclass.
Should be placed directly under RAVE_OBJECT_HEAD like in CompositeAlgorithm_t.
#define CompositeAlgorithm_fillQualityInformation | ( | self, | |
obj, | |||
howtask, | |||
quantity, | |||
field, | |||
x, | |||
y, | |||
navinfo, | |||
gain, | |||
offset ) |
Macro expansion if this algorithm supports process or not.
#define CompositeAlgorithm_getName | ( | self | ) |
Macro expansion for calling the name function.
[in] | self | - self |
#define CompositeAlgorithm_initialize | ( | self, | |
objects ) |
Macro expansion for initializing the algorithm.
[in] | self | - self |
[in] | composite | - the composite this algorithm will be working with |
#define CompositeAlgorithm_process | ( | self, | |
obj, | |||
quantity, | |||
olon, | |||
olat, | |||
dist, | |||
otype, | |||
ovalue, | |||
navinfo ) |
Macro expansion for calling the process function.
[in] | self | - self |
[in] | obj | - the polar object (currently only scan and volume) |
[in] | quantity | - the quantity we currently are working with |
[in] | olon | - the longitude in radians |
[in] | olat | - the latitude in radians |
[in] | dist | - the distance from the radar origin to the given lon/lat. |
[in,out] | otype | - the type of the data found |
[in,out] | ovalue | - the value of the data found |
[in] | navinfo | - the navigation info for the provided obj/olon/olat |
#define CompositeAlgorithm_reset | ( | self, | |
x, | |||
y ) |
Macro expansion for calling the process function.
[in] | self | - self |
#define CompositeAlgorithm_supportsFillQualityInformation | ( | self, | |
howtask ) |
Macro expansion if this algorithm supports process or not.
#define CompositeAlgorithm_supportsProcess | ( | self | ) |
Macro expansion if this algorithm supports process or not.
typedef int(* composite_algorithm_fillQualityInformation_fun) (struct _CompositeAlgorithm_t *self, RaveCoreObject *obj, const char *howtask, const char *quantity, RaveField_t *field, long x, long y, PolarNavigationInfo *navinfo, double gain, double offset) |
Function to be used when filling quality information into a rave field at pos x,y-.
[in] | self | - self |
[in] | obj | - the object that was selected for setting the composite value |
[in] | howtask | - the how/task value defining what quality attribute we are processing |
[in] | quantity | - the quantity we are working with |
[in] | field | - the quality field to be set |
[in] | x | - the x position to be set in the field |
[in] | y | - the y position to be set in the field |
[in] | navinfo | - the navigation information that was used within the rave object |
typedef const char *(* composite_algorithm_getName_fun) (struct _CompositeAlgorithm_t *self) |
typedef int(* composite_algorithm_initialize_fun) (struct _CompositeAlgorithm_t *self, struct _Composite_t *composite) |
The initializing function so that we know what composite we are working with.
Note, this function will be called by the composite module and will override any previous calls.
typedef int(* composite_algorithm_processor_fun) (struct _CompositeAlgorithm_t *self, RaveCoreObject *obj, const char *quantity, double olon, double olat, double dist,RaveValueType *otype, double *ovalue, PolarNavigationInfo *navinfo) |
The processor function definition.
[in] | self | - self |
[in] | obj | - the polar object (currently only scan and volume) |
[in] | quantity | - the quantity we currently are working with |
[in] | olon | - the longitude in radians |
[in] | olat | - the latitude in radians |
[in] | dist | - the distance from the radar origin to the given lon/lat. |
[in,out] | otype | - the type of the data found |
[in,out] | ovalue | - the value of the data found |
[in] | navinfo | - the navigation info for the provided obj/olon/olat |
typedef void(* composite_algorithm_reset_fun) (struct _CompositeAlgorithm_t *self, int x, int y) |
The resetting mechanism that will be called for each new x/y position in the composite.
This function might be useful if you want to set some start values.
typedef int(* composite_algorithm_supportsFillQualityInformation_fun) (struct _CompositeAlgorithm_t *self, const char *howtask) |
Function to be used when querying if this algorithm supports the quality field with how/task value.
typedef int(* composite_algorithm_supportsProcess_fun) (struct _CompositeAlgorithm_t *self) |
The supports process function that indicates if process is supported or not.
typedef struct _CompositeAlgorithm_t CompositeAlgorithm_t |
The basic composite algorithm that can be cast into a subclassed processor.