EMAN::BoxMaxProcessor Class Reference

peak processor: pixel = max of values surrounding pixel. More...

#include <processor.h>

Inheritance diagram for EMAN::BoxMaxProcessor:

Inheritance graph
[legend]
Collaboration diagram for EMAN::BoxMaxProcessor:

Collaboration graph
[legend]
List of all members.

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 ProcessorNEW ()

Static Public Attributes

static const string NAME = "math.localmax"

Protected Member Functions

void process_pixel (float *pixel, const float *data, int n) const

Detailed Description

peak processor: pixel = max of values surrounding pixel.

Definition at line 3054 of file processor.h.


Member Function Documentation

string EMAN::BoxMaxProcessor::get_desc (  )  const [inline, virtual]

Get the descrition of this specific processor.

This function must be overwritten by a subclass.

Returns:
The description of this processor.

Implements EMAN::Processor.

Definition at line 3066 of file processor.h.

03067                 {
03068                         return "peak processor: pixel = max of values surrounding pixel.";
03069                 }

string EMAN::BoxMaxProcessor::get_name (  )  const [inline, virtual]

Get the processor's name.

Each processor is identified by a unique name.

Returns:
The processor's name.

Implements EMAN::Processor.

Definition at line 3057 of file processor.h.

References NAME.

03058                 {
03059                         return NAME;
03060                 }

static Processor* EMAN::BoxMaxProcessor::NEW (  )  [inline, static]

Definition at line 3061 of file processor.h.

03062                 {
03063                         return new BoxMaxProcessor();
03064                 }

void EMAN::BoxMaxProcessor::process_pixel ( float *  pixel,
const float *  data,
int  n 
) const [inline, protected, virtual]

Implements EMAN::BoxStatProcessor.

Definition at line 3074 of file processor.h.

03075                 {
03076                         float maxval = -FLT_MAX;
03077                         for (int i = 0; i < n; i++)
03078                         {
03079                                 if (data[i] > maxval) {
03080                                         maxval = data[i];
03081                                 }
03082                         }
03083                          *pixel = maxval;
03084                 }


Member Data Documentation

const string BoxMaxProcessor::NAME = "math.localmax" [static]

Definition at line 3071 of file processor.h.

Referenced by get_name().


The documentation for this class was generated from the following files:
Generated on Thu Nov 17 12:46:19 2011 for EMAN2 by  doxygen 1.4.7