claw::graphic::png::reader::source_manager Struct Reference

#include <png.hpp>

List of all members.


Detailed Description

Source manager that allow us to read from a std::istream.

Author:
Julien Jorge

Definition at line 64 of file png.hpp.


Public Member Functions

 source_manager (std::istream &is)
 Constructor.
void read (png_bytep data, png_size_t length)
 Read data from the input stream.

Private Attributes

std::istream & m_input
 The stream from which we get data.

Constructor & Destructor Documentation

claw::graphic::png::reader::source_manager::source_manager ( std::istream &  is  ) 

Constructor.

Parameters:
is The stream we read from.

Definition at line 61 of file png_reader.cpp.

References CLAW_PRECOND.

00062   : m_input(is)
00063 {
00064   CLAW_PRECOND( !!is );
00065 } // png::reader::source_manager::source_manager()


Member Function Documentation

void claw::graphic::png::reader::source_manager::read ( png_bytep  data,
png_size_t  length 
)

Read data from the input stream.

Parameters:
data (out) Array of the bytes we have read.
length Number of bytes to read.

Definition at line 74 of file png_reader.cpp.

References m_input.

00075 {
00076   m_input.read( (char*)data, length * sizeof(png_byte) );
00077 } // png::reader::source_manager::read()


Member Data Documentation

The stream from which we get data.

Definition at line 73 of file png.hpp.

Referenced by read().


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

Generated on Thu Jun 26 09:35:06 2008 for CLAW Library (a C++ Library Absolutely Wonderful) by  doxygen 1.5.6