#include <processor.h>
Inheritance diagram for EMAN::MinusPeakProcessor:
Public Member Functions | |
string | get_name () const |
Get the processor's name. | |
string | get_desc () const |
Get the descrition of this specific processor. | |
Static Public Member Functions | |
static Processor * | NEW () |
Static Public Attributes | |
static const string | NAME = "math.submax" |
Protected Member Functions | |
void | process_pixel (float *pixel, const float *data, int n) const |
This is a sort of positive peak-finding algorithm.
Definition at line 3136 of file processor.h.
string EMAN::MinusPeakProcessor::get_desc | ( | ) | const [inline, virtual] |
Get the descrition of this specific processor.
This function must be overwritten by a subclass.
Implements EMAN::Processor.
Definition at line 3148 of file processor.h.
03149 { 03150 return "peak processor: pixel = pixel - max of values surrounding pixel. This is a sort of positive peak-finding algorithm."; 03151 }
string EMAN::MinusPeakProcessor::get_name | ( | ) | const [inline, virtual] |
Get the processor's name.
Each processor is identified by a unique name.
Implements EMAN::Processor.
Definition at line 3139 of file processor.h.
References NAME.
03140 { 03141 return NAME; 03142 }
static Processor* EMAN::MinusPeakProcessor::NEW | ( | ) | [inline, static] |
void EMAN::MinusPeakProcessor::process_pixel | ( | float * | pixel, | |
const float * | data, | |||
int | n | |||
) | const [inline, protected, virtual] |
Implements EMAN::BoxStatProcessor.
Definition at line 3156 of file processor.h.
03157 { 03158 float maxval = -FLT_MAX; 03159 for (int i = 0; i < n; i++) 03160 { 03161 if (data[i] > maxval) { 03162 maxval = data[i]; 03163 } 03164 } 03165 *pixel -= maxval; 03166 }
const string MinusPeakProcessor::NAME = "math.submax" [static] |