firevision::HistogramFile Class Reference

A fileformat for histograms. More...

#include <fvutils/statistical/histogram_file.h>

Inheritance diagram for firevision::HistogramFile:

[legend]
List of all members.

Public Types

typedef std::list< HistogramBlock * > HistogramBlockList
 Convenience typdef for a STL list of pointers to histogram blocks.

Public Member Functions

 HistogramFile ()
 Constructor.
 ~HistogramFile ()
 Destructor.
void add_histogram_block (HistogramBlock *block)
 Adds a new histogram block to the file.
HistogramBlockList histogram_blocks ()
 Generates a list of histogram blocks attached to the file.
uint32_t get_value (hint_t object_type, uint16_t x, uint16_t y, uint16_t z)
 Get a value from a certain histogram.
void set_value (hint_t object_type, uint16_t x, uint16_t y, uint16_t z, uint32_t val)
 Set a value in a certain histogram.

Detailed Description

A fileformat for histograms.

Such a file might contain multiple histograms, each for a a different type of object.

Author:
Daniel Beck

Definition at line 42 of file histogram_file.h.


Member Typedef Documentation

typedef std::list<HistogramBlock*> firevision::HistogramFile::HistogramBlockList

Convenience typdef for a STL list of pointers to histogram blocks.

Definition at line 51 of file histogram_file.h.


Constructor & Destructor Documentation

firevision::HistogramFile::HistogramFile (  ) 

Constructor.

Definition at line 42 of file histogram_file.cpp.

firevision::HistogramFile::~HistogramFile (  ) 

Destructor.

Definition at line 50 of file histogram_file.cpp.


Member Function Documentation

void firevision::HistogramFile::add_histogram_block ( HistogramBlock block  ) 

Adds a new histogram block to the file.

Parameters:
block the histogram block

Definition at line 60 of file histogram_file.cpp.

References firevision::FireVisionDataFile::add_block(), and firevision::HistogramBlock::object_type().

Referenced by firevision::Histogram::save(), and firevision::BayesColormapGenerator::save_histograms().

uint32_t firevision::HistogramFile::get_value ( hint_t  object_type,
uint16_t  x,
uint16_t  y,
uint16_t  z 
)

Get a value from a certain histogram.

Parameters:
object_type the requested value is obtained from the histogram for this type of object
x the x-coordinate
y the y-coordinate
z the z-coordinate
Returns:
value

Definition at line 104 of file histogram_file.cpp.

HistogramFile::HistogramBlockList firevision::HistogramFile::histogram_blocks (  ) 

Generates a list of histogram blocks attached to the file.

Returns:
a list of all attached histogram blocks

Definition at line 74 of file histogram_file.cpp.

References firevision::FireVisionDataFile::blocks(), firevision::FIREVISION_HISTOGRAM_TYPE_16, and firevision::FIREVISION_HISTOGRAM_TYPE_32.

Referenced by firevision::BayesColormapGenerator::load_histograms().

void firevision::HistogramFile::set_value ( hint_t  object_type,
uint16_t  x,
uint16_t  y,
uint16_t  z,
uint32_t  val 
)

Set a value in a certain histogram.

Parameters:
object_type this specifies the type for which the respective histogram is changed
x the x-coordinate
y the y-coordinate
z the z-coordinate
val the new value for the specified cell

Definition at line 122 of file histogram_file.cpp.


The documentation for this class was generated from the following files:
Generated on Tue Feb 22 13:31:44 2011 for Fawkes API by  doxygen 1.4.7