Main Page   Modules   Alphabetical List   Data Structures   Data Fields  

RtPNG
[Image Conversion Tools]


Functions

RwImage RtPNGImageWrite (RwImage *image, const RwChar *imageName)
RwImage RtPNGImageRead (const RwChar *imageName)

Detailed Description

PNG/Portable Network Graphics Image Format Toolkit for RenderWare.

See also http://www.libpng.org/pub/png/

RtPNG Toolkit Overview

Requirements

Overview

The PNG - Portable Network Graphics - image file format is a relative newcomer to the graphics scene. It was designed primarily in response to the unexpected decision by Unisys to enforce its patent on LZW compression long after the GIF file format, which relies on LZW, had entered widespread use.

The PNG format supports both palettized (8-bit) images as well as RGBA image formats. As a result, it can be used instead of either the GIF and JPEG image formats for most purposes.

Unlike the GIF-89a format, the PNG file format does not support animation.

The RtPNG toolkit provides reading and writing functions for the Portable Network Graphics (‘PNG’) image format.


Function Documentation

RwImage* RtPNGImageRead const RwChar   imageName
 

RtPNGImageRead is used to read a Portable Network Graphics format file from disk. It reads a PNG file using libpng of http://www.libpng.org/pub/png and return as an RwImage.

The file name can either be absolute or relative to the directory the application is running from. The image search path is not used to find image files and no gamma correction is applied to the image as it is read.

Note that the include file rtpng.h is required and must be included by an application wishing to load PNG format files. The PNG library is contained in the file rtpng.lib.

Parameters:
imageName  Pointer to the filename to load.
Returns:
RwImage * on success, or NULL on failure.
See also:
RtPNGImageWrite , RwImageRead , RwImageWrite , RwImageRegisterImageFormat
RwImage* RtPNGImageWrite RwImage   image,
const RwChar   imageName
 

RtPNGImageWrite writes a PNG file, using libpng of http://www.libpng.org/pub/png

Parameters:
image  Pointer to the image to be written.
imageName  Pointer to the filename of the image.
Returns:
RwImage * on success, or NULL on failure.
See also:
RtPNGImageRead , RwImageRead , RwImageWrite

Criterion Software © 1993-2003 Criterion Software Limited. All rights reserved. Built Tue Apr 22 12:46:59 2003. Send Feedback
Converted from CHM to HTML with chm2web Pro 2.85 (unicode)