Fawkes API  Fawkes Development Version
firevision::PNMWriter Class Reference

PNM file writer. More...

#include <>>

Inheritance diagram for firevision::PNMWriter:

Public Member Functions

 PNMWriter (PNMFormat format)
 Constructor. More...
 
 PNMWriter (PNMFormat format, const char *filename, unsigned int width, unsigned int height)
 Constructor. More...
 
virtual void set_buffer (colorspace_t cspace, unsigned char *buffer)
 Set image buffer. More...
 
virtual void write ()
 Write to file. More...
 
- Public Member Functions inherited from firevision::Writer
 Writer (const char *extension=0)
 Constructor. More...
 
virtual ~Writer ()
 Virtual empty destructor. More...
 
virtual void set_filename (const char *filename)
 Set filename. More...
 
virtual void set_dimensions (unsigned int width, unsigned int height)
 Set dimensions of image in pixels. More...
 

Additional Inherited Members

- Protected Member Functions inherited from firevision::Writer
virtual void set_extension (const char *extension)
 Set the filename extension for file written by this writer. More...
 
- Protected Attributes inherited from firevision::Writer
char * filename
 The complete filename. More...
 
char * basename
 The basename of the file. More...
 
char * extension
 The extension of the file. More...
 
unsigned int width
 The width of the image. More...
 
unsigned int height
 The height of the image. More...
 
colorspace_t cspace
 The colorspace of the image. More...
 
unsigned char * buffer
 The image-buffer. More...
 

Detailed Description

PNM file writer.

Definition at line 49 of file pnm.h.

Constructor & Destructor Documentation

◆ PNMWriter() [1/2]

firevision::PNMWriter::PNMWriter ( PNMFormat  format)

Constructor.

Parameters
formatPNM subformat

Definition at line 46 of file pnm.cpp.

◆ PNMWriter() [2/2]

firevision::PNMWriter::PNMWriter ( PNMFormat  format,
const char *  filename,
unsigned int  width,
unsigned int  height 
)

Constructor.

Parameters
formatPNM subformat
filenamefilename
widthimage width
heightimage height

Definition at line 62 of file pnm.cpp.

References firevision::Writer::set_filename().

Member Function Documentation

◆ set_buffer()

void firevision::PNMWriter::set_buffer ( colorspace_t  cspace,
unsigned char *  buffer 
)
virtual

Set image buffer.

Parameters
cspacecolor space of image
bufferbuffer of image

Reimplemented from firevision::Writer.

Definition at line 78 of file pnm.cpp.

◆ write()

void firevision::PNMWriter::write ( )
virtual

Write to file.

Implements firevision::Writer.

Definition at line 228 of file pnm.cpp.

References firevision::Writer::filename.


The documentation for this class was generated from the following files: