Crystal Space: csCommonImageFileLoader Class Reference (Crystal Space Public API Reference)

| ## Public API Reference

- Main Page
- Modules
- Namespaces
- Classes
- Files
- Related Pages

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# csCommonImageFileLoader Class Reference
[Common Plugin Classes]

Base image loader implementation. More...

`#include <csplugincommon/imageloader/commonimagefile.h>`

Inheritance diagram for csCommonImageFileLoader:

[legend]
List of all members.

## Public Member Functions
virtual void | ApplyTo (csImageMemory *image)
| Copy the image data into an image object.
virtual csLoaderDataType | GetDataType ()
| Return type of raw data.
virtual int | GetFormat ()
| Query format.
virtual int | GetHeight ()
| Query height.
virtual void | GetKeyColor (int &r, int &g, int &b) const
| Query keycolor.
virtual csRef< iDataBuffer > | GetRawData ()
| Return "raw data" (if supported).
virtual int | GetWidth ()
| Query width.
virtual bool | HasKeyColor () const
| Query whether a keycolor is set.
## Protected Attributes
uint8 * | alpha
| Alpha data for indexed images.
csLoaderDataType | dataType
| The type of image data this loader provides.
int | Format
| Format of the image.
bool | hasKeycolor
| Whether the image has a keycolor.
int | Height
uint8 * | indexData
| Pointer to indexed data (if dataType == rdtIndexed).
csRGBcolor | keycolor
| Keycolor.
csRGBpixel * | palette
| Palette for indexed colors.
size_t | paletteCount
| Number of entries in the palette.
csRef< iDataBuffer > | rawData
| Buffer with raw data.
csRGBpixel * | rgbaData
| Pointer to RGBA data (if dataType == rdtRGBpixel).
int | Width
| Image dimensions.

## Detailed Description

Base image loader implementation.

Definition at line 89 of file commonimagefile.h.

## Member Function Documentation

virtual void csCommonImageFileLoader::ApplyTo | ( | csImageMemory * | image | ) | `[virtual]`

Copy the image data into an image object.

Implements iImageFileLoader.

virtual csLoaderDataType csCommonImageFileLoader::GetDataType | ( |  | ) | `[inline, virtual]`

Return type of raw data.

Implements iImageFileLoader.

Definition at line 121 of file commonimagefile.h.

virtual int csCommonImageFileLoader::GetFormat | ( |  | ) | `[inline, virtual]`

Query format.

Implements iImageFileLoader.

Definition at line 125 of file commonimagefile.h.

virtual int csCommonImageFileLoader::GetHeight | ( |  | ) | `[inline, virtual]`

Query height.

Implements iImageFileLoader.

Definition at line 124 of file commonimagefile.h.

virtual void csCommonImageFileLoader::GetKeyColor | ( | int & | r,
|  | int & | g,
|  | int & | b |
| ) |  |  | const`[inline, virtual]`

Query keycolor.

Implements iImageFileLoader.

Definition at line 128 of file commonimagefile.h.

virtual csRef<iDataBuffer> csCommonImageFileLoader::GetRawData | ( |  | ) | `[inline, virtual]`

Return "raw data" (if supported).

Implements iImageFileLoader.

Definition at line 119 of file commonimagefile.h.

virtual int csCommonImageFileLoader::GetWidth | ( |  | ) | `[inline, virtual]`

Query width.

Implements iImageFileLoader.

Definition at line 123 of file commonimagefile.h.

virtual bool csCommonImageFileLoader::HasKeyColor | ( |  | ) | const`[inline, virtual]`

Query whether a keycolor is set.

Implements iImageFileLoader.

Definition at line 127 of file commonimagefile.h.

## Member Data Documentation

uint8* csCommonImageFileLoader::alpha`[protected]`

Alpha data for indexed images.

Definition at line 108 of file commonimagefile.h.

csLoaderDataType csCommonImageFileLoader::dataType`[protected]`

The type of image data this loader provides.

Definition at line 98 of file commonimagefile.h.

int csCommonImageFileLoader::Format`[protected]`

Format of the image.

Definition at line 94 of file commonimagefile.h.

bool csCommonImageFileLoader::hasKeycolor`[protected]`

Whether the image has a keycolor.

Definition at line 110 of file commonimagefile.h.

uint8* csCommonImageFileLoader::indexData`[protected]`

Pointer to indexed data (if dataType == rdtIndexed).

Definition at line 102 of file commonimagefile.h.

csRGBcolor csCommonImageFileLoader::keycolor`[protected]`

Keycolor.

Definition at line 112 of file commonimagefile.h.

csRGBpixel* csCommonImageFileLoader::palette`[protected]`

Palette for indexed colors.

Definition at line 104 of file commonimagefile.h.

size_t csCommonImageFileLoader::paletteCount`[protected]`

Number of entries in the palette.

Definition at line 106 of file commonimagefile.h.

csRef<iDataBuffer> csCommonImageFileLoader::rawData`[protected]`

Buffer with raw data.

Definition at line 96 of file commonimagefile.h.

csRGBpixel* csCommonImageFileLoader::rgbaData`[protected]`

Pointer to RGBA data (if dataType == rdtRGBpixel).

Definition at line 100 of file commonimagefile.h.

int csCommonImageFileLoader::Width`[protected]`

Image dimensions.

Definition at line 114 of file commonimagefile.h.

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

- csplugincommon/imageloader/commonimagefile.h