pnm Class Reference

Allow reading and writing PNM files. More...

#include <pnm.h>

List of all members.

Static Public Member Functions

static void * get (SDL_RWops *file, u_int16 *length, u_int16 *height)
 Reads a PNM image from an opened file.
static void put (SDL_RWops *file, void *image, u_int16 length, u_int16 height)
 Saves a PNM image into an opened file.

Detailed Description

Allow reading and writing PNM files.

Definition at line 31 of file pnm.h.


Member Function Documentation

void * pnm::get ( SDL_RWops *  file,
u_int16 *  length,
u_int16 *  height 
) [static]

Reads a PNM image from an opened file.

Warning:
The returned pointer is allocated by this function with calloc (). Don't forget to free () it when you don't need it anymore!
Parameters:
file opened file from which to read.
length pointer to the integer which will contain the image's length.
height pointer to the integer which will contain the image's height.
Returns:
allocated pointer containing the PNM image.

Definition at line 33 of file pnm.cc.

void pnm::put ( SDL_RWops *  file,
void *  image,
u_int16  length,
u_int16  height 
) [static]

Saves a PNM image into an opened file.

Parameters:
file the opened file to write the PNM image to.
image the PNM image data.
length the length of the image to write.
height the height of the image to write.

Definition at line 78 of file pnm.cc.


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

Generated on 27 Nov 2009 for Adonthell by  doxygen 1.6.1