//===========================================================================//
// File:	 targa.h 													 //
// Project:  Window Library			                                         //
// Contents: Code to make basic button workd								 //
//---------------------------------------------------------------------------//
// Copyright (C) 1999 Microsoft Corp.						                 //
// All Rights reserved worldwide                                             //
// This unpublished sourcecode is PROPRIETARY and CONFIDENTIAL               //
//===========================================================================//

#ifndef TARGA_H
#define TARGA_H

#define TGA_SIZE        18
typedef struct  tgaheader {   /* Offset          Meaning              */
         BYTE IdSize;       /*  0   id field size at end of header  */
         BYTE ColMapType;   /*  1   0=>no color map, 1=>color map   */
         BYTE TypeCode;     /*  2   1=>type 1, 2=>type 2 images,... */
         WORD ColMapOrigin; /*  3   index of first color map entry  */
         WORD ColMapLength; /*  5   number of entries in color map  */
         BYTE ColMapBits;   /*  7   number of bits/color map entry  */
         WORD XOrigin;      /*  8   lower left corner of image      */
         WORD YOrigin;      /*  10  lower left corner of image      */
         WORD Width;        /*  12  width of image in pixels        */
         WORD Height;       /*  14  height of image in pixels       */
         BYTE BitsPerPixel; /*  16  see note 1: below               */
         BYTE Descriptor;   /*  17  see note 2: below               */
         /*                                                          */
         /* Note 1: The "BitsPerPixel" field depends of the type of  */
         /*         Targa file. For Targa type 1 images, it is the   */
         /*         number of bits per pixel index.  For a true-     */
         /*         color Targa image this is 24, since pixels need  */
         /*         1 byte each for r, g, and b.                     */
         /* Note 2: Individual bits have meaning here. For example,  */
         /*         toggling bit 5 flips the image upside down.      */
} TGAHeader;

#define TGA_FILE 		1			//Display from a file
#define TGA_RESOURCE 2			//Display from resource ID
#define TGA_MATTE    4			//Don't show black (0,0,0) areas
#define TGA_OPAQUE	8			//Show completely
#define TGA_LZ			16			//Comes from graphics.lz

class FileType;

extern FileType *gLZGraphics;
//Modes for displaying
#endif
