Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

PLPictDecoder Class Reference

This class decodes macintosh PICT files with 1,2,4,8,16 and 32 bits per pixel as well as PICT/JPEG. More...

#include <plpictdec.h>

Inheritance diagram for PLPictDecoder:

Inheritance graph
[legend]
Collaboration diagram for PLPictDecoder:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 PLPictDecoder (PLJPEGDecoder *pJPEGDecoder)
 Creates a decoder.
virtual ~PLPictDecoder ()
 Destroys a decoder.

Protected Member Functions

virtual void DoDecode (PLBmp *pBmp, PLDataSource *pDataSrc)
 Does the actual decoding after a data source has been set up.

Private Member Functions

void readHeader (PLDataSource *pDataSrc, int &Version)
void interpretOpcodes (PLBmp *pBmp, PLDataSource *pDataSrc, int &Version)
PLWORD readOpcode (int Version, PLDataSource *pDataSrc)
void clip (PLDataSource *pDataSrc)
void pixPat (PLDataSource *pDataSrc)
void skipPolyOrRegion (PLDataSource *pDataSrc)
void bitsRect (PLDataSource *pDataSrc, PLBmp *pBmp)
void bitsRegion (PLDataSource *pDataSrc, PLBmp *pBmp)
void opcode9a (PLDataSource *pDataSrc, PLBmp *pBmp)
void longComment (PLDataSource *pDataSrc)
void headerOp (PLDataSource *pDataSrc, PLBmp *pBmp)
void jpegOp (PLDataSource *pDataSrc, PLBmp *pBmp)
void createOutputBmp (MacpixMap PixMap, PLBmp *pBmp)
void doBitmap (int rowBytes, bool bIsRegion, PLBmp *pBmp, PLDataSource *pDataSrc)
void doPixmap (int rowBytes, bool bIsRegion, PLBmp *pBmp, PLDataSource *pDataSrc)
void unpack32bits (MacRect *pBounds, PLWORD rowBytes, int NumBitPlanes, PLBmp *pBmp, PLDataSource *pDataSrc)
void unpack8bits (MacRect *pBounds, PLWORD rowBytes, PLBmp *pBmp, PLDataSource *pDataSrc)
void unpackbits (MacRect *pBounds, PLWORD rowBytes, int pixelSize, PLBmp *pBmp, PLDataSource *pDataSrc)
void skipBits (MacRect *pBounds, PLWORD rowBytes, int pixelSize, PLDataSource *pDataSrc)
void expandBuf (PLBYTE *pDestBuf, PLBYTE *pSrcBuf, int Width, int bpp)
void expandBuf8 (PLBYTE *pDestBuf, PLBYTE *pSrcBuf, int Width, int bpp)
void readPixmap (MacpixMap *pPixMap, PLDataSource *pDataSrc)
void readColourTable (PLWORD *pNumColors, PLDataSource *pDataSrc, PLPixel32 *pPal)
void readRect (MacRect *pr, PLDataSource *pDataSrc)
void dumpRect (char *psz, MacRect *pr)
void tracePixMapHeader (int Level, MacpixMap *pPixMap)

Private Attributes

PLJPEGDecoderm_pJPEGDecoder
PLPoint m_Resolution

Detailed Description

This class decodes macintosh PICT files with 1,2,4,8,16 and 32 bits per pixel as well as PICT/JPEG.

If an alpha channel is present in a 32-bit-PICT, it is decoded as well. The PICT format is a general picture file format and can contain a lot of other elements besides bitmaps. These elements are ignored.

Definition at line 28 of file plpictdec.h.


Constructor & Destructor Documentation

PLPictDecoder::PLPictDecoder PLJPEGDecoder pJPEGDecoder  ) 
 

Creates a decoder.

A JPEG decoder is needed to decode PICT files containing JPEGs.

Definition at line 31 of file plpictdec.cpp.

PLPictDecoder::~PLPictDecoder  )  [virtual]
 

Destroys a decoder.

Definition at line 42 of file plpictdec.cpp.


Member Function Documentation

void PLPictDecoder::bitsRect PLDataSource pDataSrc,
PLBmp pBmp
[private]
 

Definition at line 317 of file plpictdec.cpp.

References PLWORD.

void PLPictDecoder::bitsRegion PLDataSource pDataSrc,
PLBmp pBmp
[private]
 

Definition at line 333 of file plpictdec.cpp.

References PLWORD.

void PLPictDecoder::clip PLDataSource pDataSrc  )  [private]
 

Definition at line 256 of file plpictdec.cpp.

References PLWORD.

void PLPictDecoder::createOutputBmp MacpixMap  PixMap,
PLBmp pBmp
[private]
 

Definition at line 457 of file plpictdec.cpp.

void PLPictDecoder::doBitmap int  rowBytes,
bool  bIsRegion,
PLBmp pBmp,
PLDataSource pDataSrc
[private]
 

Definition at line 478 of file plpictdec.cpp.

References MacRect::bottom, MacRect::left, PLWORD, MacRect::right, and MacRect::top.

void PLPictDecoder::DoDecode PLBmp pBmp,
PLDataSource pDataSrc
[protected, virtual]
 

Does the actual decoding after a data source has been set up.

Reimplemented from PLPicDecoder.

Definition at line 48 of file plpictdec.cpp.

void PLPictDecoder::doPixmap int  rowBytes,
bool  bIsRegion,
PLBmp pBmp,
PLDataSource pDataSrc
[private]
 

Definition at line 519 of file plpictdec.cpp.

References MacpixMap::Bounds, MacpixMap::cmpCount, MacpixMap::pixelSize, and PLWORD.

void PLPictDecoder::dumpRect char *  psz,
MacRect pr
[private]
 

Definition at line 1120 of file plpictdec.cpp.

void PLPictDecoder::expandBuf PLBYTE pDestBuf,
PLBYTE pSrcBuf,
int  Width,
int  bpp
[private]
 

Definition at line 921 of file plpictdec.cpp.

References PL_ERRFORMAT_UNKNOWN, PLBYTE, PLWORD, and raiseError().

Here is the call graph for this function:

void PLPictDecoder::expandBuf8 PLBYTE pDestBuf,
PLBYTE pSrcBuf,
int  Width,
int  bpp
[private]
 

Definition at line 959 of file plpictdec.cpp.

References PL_ERRFORMAT_UNKNOWN, PLBYTE, and raiseError().

Here is the call graph for this function:

void PLPictDecoder::headerOp PLDataSource pDataSrc,
PLBmp pBmp
[private]
 

Definition at line 402 of file plpictdec.cpp.

void PLPictDecoder::interpretOpcodes PLBmp pBmp,
PLDataSource pDataSrc,
int &  Version
[private]
 

Definition at line 110 of file plpictdec.cpp.

References clip, PL_ERRFORMAT_NOT_SUPPORTED, PL_ERRFORMAT_UNKNOWN, PLWORD, and raiseError().

Here is the call graph for this function:

void PLPictDecoder::jpegOp PLDataSource pDataSrc,
PLBmp pBmp
[private]
 

Definition at line 415 of file plpictdec.cpp.

References PL_ERRFORMAT_NOT_SUPPORTED, PLBYTE, and raiseError().

Here is the call graph for this function:

void PLPictDecoder::longComment PLDataSource pDataSrc  )  [private]
 

Definition at line 389 of file plpictdec.cpp.

References PLWORD.

void PLPictDecoder::opcode9a PLDataSource pDataSrc,
PLBmp pBmp
[private]
 

Definition at line 349 of file plpictdec.cpp.

References MacpixMap::Bounds, MacpixMap::cmpCount, MacpixMap::pixelSize, and PLWORD.

void PLPictDecoder::pixPat PLDataSource pDataSrc  )  [private]
 

Definition at line 273 of file plpictdec.cpp.

References MacpixMap::Bounds, MacpixMap::pixelSize, PL_ERRFORMAT_UNKNOWN, PLWORD, and raiseError().

Here is the call graph for this function:

void PLPictDecoder::readColourTable PLWORD pNumColors,
PLDataSource pDataSrc,
PLPixel32 pPal
[private]
 

Definition at line 1064 of file plpictdec.cpp.

References PL_ERRFORMAT_UNKNOWN, PLBYTE, PLLONG, PLWORD, raiseError(), PLPixel32::SetB(), PLPixel32::SetG(), and PLPixel32::SetR().

Here is the call graph for this function:

void PLPictDecoder::readHeader PLDataSource pDataSrc,
int &  Version
[private]
 

Definition at line 68 of file plpictdec.cpp.

References PL_ERRWRONG_SIGNATURE, PLBYTE, PLWORD, and raiseError().

Here is the call graph for this function:

PLWORD PLPictDecoder::readOpcode int  Version,
PLDataSource pDataSrc
[private]
 

Definition at line 236 of file plpictdec.cpp.

void PLPictDecoder::readPixmap MacpixMap pPixMap,
PLDataSource pDataSrc
[private]
 

Definition at line 1043 of file plpictdec.cpp.

void PLPictDecoder::readRect MacRect pr,
PLDataSource pDataSrc
[private]
 

Definition at line 1108 of file plpictdec.cpp.

void PLPictDecoder::skipBits MacRect pBounds,
PLWORD  rowBytes,
int  pixelSize,
PLDataSource pDataSrc
[private]
 

Definition at line 876 of file plpictdec.cpp.

References PLWORD.

void PLPictDecoder::skipPolyOrRegion PLDataSource pDataSrc  )  [private]
 

Definition at line 309 of file plpictdec.cpp.

void PLPictDecoder::tracePixMapHeader int  Level,
MacpixMap pPixMap
[private]
 

Definition at line 1132 of file plpictdec.cpp.

void PLPictDecoder::unpack32bits MacRect pBounds,
PLWORD  rowBytes,
int  NumBitPlanes,
PLBmp pBmp,
PLDataSource pDataSrc
[private]
 

Definition at line 566 of file plpictdec.cpp.

References MacRect::bottom, MacRect::left, PLBYTE, PLWORD, MacRect::right, PLPixel32::SetA(), PLPixel32::SetB(), PLPixel32::SetG(), PLPixel32::SetR(), and MacRect::top.

Here is the call graph for this function:

void PLPictDecoder::unpack8bits MacRect pBounds,
PLWORD  rowBytes,
PLBmp pBmp,
PLDataSource pDataSrc
[private]
 

Definition at line 652 of file plpictdec.cpp.

References PLBYTE, and PLWORD.

void PLPictDecoder::unpackbits MacRect pBounds,
PLWORD  rowBytes,
int  pixelSize,
PLBmp pBmp,
PLDataSource pDataSrc
[private]
 

Definition at line 701 of file plpictdec.cpp.

References PL_ERRFORMAT_UNKNOWN, PLBYTE, PLWORD, and raiseError().

Here is the call graph for this function:


Member Data Documentation

PLJPEGDecoder* PLPictDecoder::m_pJPEGDecoder [private]
 

Definition at line 245 of file plpictdec.h.

PLPoint PLPictDecoder::m_Resolution [private]
 

Definition at line 246 of file plpictdec.h.


The documentation for this class was generated from the following files:
Generated on Wed Dec 15 21:21:01 2004 for vuVolume by  doxygen 1.3.9.1