Panda3D
 All Classes Functions Variables Enumerations
Public Member Functions
PNMImageHeader::Histogram Class Reference

List of all members.

Public Member Functions

int get_count (int n) const
 Returns the number of occurrences in the image of the nth unique pixel color in the histogram.
int get_count (const PixelSpec &pixel) const
 Returns the number of occurrences in the image of the indicated pixel color.
int get_num_pixels () const
 Returns the number of unique pixel colors in the histogram.
const PixelSpecget_pixel (int n) const
 Returns the nth unique pixel color in the histogram.
 MAKE_SEQ (get_pixels, get_num_pixels, get_pixel)
void swap (PixelCount &pixels, HistMap &hist_map)
 Swaps the data in the Histogram with the indicated data.
void write (ostream &out) const

Detailed Description

Definition at line 160 of file pnmImageHeader.h.


Member Function Documentation

int PNMImageHeader::Histogram::get_count ( int  n) const [inline]

Returns the number of occurrences in the image of the nth unique pixel color in the histogram.

Definition at line 591 of file pnmImageHeader.I.

int PNMImageHeader::Histogram::get_count ( const PixelSpec pixel) const [inline]

Returns the number of occurrences in the image of the indicated pixel color.

Definition at line 603 of file pnmImageHeader.I.

Returns the number of unique pixel colors in the histogram.

Definition at line 567 of file pnmImageHeader.I.

Returns the nth unique pixel color in the histogram.

These are ordered by default from most common to least common.

Definition at line 579 of file pnmImageHeader.I.

void PNMImageHeader::Histogram::swap ( PixelCount &  pixels,
HistMap &  hist_map 
) [inline]

Swaps the data in the Histogram with the indicated data.

This is normally used to load the Histogram data initially in PNMImage::make_histogram().

Definition at line 620 of file pnmImageHeader.I.

Referenced by PNMImage::make_histogram().


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations