- Main Page
- Classes
- Files

- File List
- File Members

# flTexturePCX.h File Reference

`#include "flGlobal.h"`
`#include "flTexture.h"`

Go to the source code of this file.

## Functions
Texture * | texLoadPCX (char *inPath)
| Loads a pcx image into a Texture struct.
bool | texSavePCX (Texture *inTex, char *inPath)
| Saves a pcx image from a Texture struct.

## Function Documentation

Texture* texLoadPCX | ( | char * | inPath | ) |

Loads a pcx image into a Texture struct.

Parameters:

  | inPath | Path to the pcx image in memory or file.

Returns:
  A pointer to the texture struct created to hold the pcx, or NULL on failure.

Definition at line 39 of file flTexturePCX.c.

References pcxFileHeader::bpp, pcxFileHeader::bytesPerLine, pcxFileHeader::colorPlanes, debugError, pcxFileHeader::encoding, FILE_MODE_BINARY, FILE_MODE_READ, fileClose(), fileOpen(), fileRead(), pcxFileHeader::filler, pcxFileHeader::horizontalDPI, pcxFileHeader::hScrSize, pcxFileHeader::manufacturer, memQalloc, NULL, pcxFileHeader::palette, pcxFileHeader::paletteType, pcxFileHeader::reserved, pcxFileHeader::version, pcxFileHeader::verticalDPI, pcxFileHeader::vScrSize, pcxFileHeader::xMax, pcxFileHeader::xMin, pcxFileHeader::yMax, and pcxFileHeader::yMin.

Referenced by texLoad().

bool texSavePCX | ( | Texture * | inTex,
|  | char * | inPath |
| ) |  |  |

Saves a pcx image from a Texture struct.

Parameters:

  | inTex | The texture to save as a pcx.
  | inPath | Path to the file to which the pcx image will be written.

Returns:
  Whether the pcx was saved successfully or not.

Warning:
  This will always return false an log an error as it is not yet implemented.

Definition at line 260 of file flTexturePCX.c.

References debugWarning.

Referenced by texSave().