Public Member Functions | Private Member Functions | Private Attributes | List of all members
lvr2::PPMIO Class Reference

An implementation of the PPM file format. More...

#include <PPMIO.hpp>

Public Member Functions

int getHeight () const
 
unsigned char * getPixels () const
 
int getWidth () const
 
 PPMIO ()
 
 PPMIO (string filename)
 
void setDataArray (unsigned char *array, int width, int height)
 
void write (string filename)
 
virtual ~PPMIO ()
 

Private Member Functions

void readLine (ifstream &in, char *buffer)
 

Private Attributes

int m_height
 
unsigned char * m_pixels
 
int m_width
 

Detailed Description

An implementation of the PPM file format.

Definition at line 59 of file PPMIO.hpp.

Constructor & Destructor Documentation

◆ PPMIO() [1/2]

lvr2::PPMIO::PPMIO ( )

Definition at line 50 of file PPMIO.cpp.

◆ PPMIO() [2/2]

lvr2::PPMIO::PPMIO ( string  filename)

Definition at line 57 of file PPMIO.cpp.

◆ ~PPMIO()

virtual lvr2::PPMIO::~PPMIO ( )
inlinevirtual

Definition at line 64 of file PPMIO.hpp.

Member Function Documentation

◆ getHeight()

int lvr2::PPMIO::getHeight ( ) const
inline

Definition at line 69 of file PPMIO.hpp.

◆ getPixels()

unsigned char* lvr2::PPMIO::getPixels ( ) const
inline

Definition at line 71 of file PPMIO.hpp.

◆ getWidth()

int lvr2::PPMIO::getWidth ( ) const
inline

Definition at line 70 of file PPMIO.hpp.

◆ readLine()

void lvr2::PPMIO::readLine ( ifstream &  in,
char *  buffer 
)
private

Reads a new line from the given stream that is no comment

Parameters
inThe stream to read from
bufferThe extracted information

Definition at line 150 of file PPMIO.cpp.

◆ setDataArray()

void lvr2::PPMIO::setDataArray ( unsigned char *  array,
int  width,
int  height 
)

Definition at line 143 of file PPMIO.cpp.

◆ write()

void lvr2::PPMIO::write ( string  filename)

Definition at line 129 of file PPMIO.cpp.

Member Data Documentation

◆ m_height

int lvr2::PPMIO::m_height
private

Definition at line 75 of file PPMIO.hpp.

◆ m_pixels

unsigned char* lvr2::PPMIO::m_pixels
private

Definition at line 76 of file PPMIO.hpp.

◆ m_width

int lvr2::PPMIO::m_width
private

Definition at line 74 of file PPMIO.hpp.


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


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:12