Advanced Strategic Command
Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
TypedSurface< colorDepth > Class Template Reference

#include <surface.h>

Inheritance diagram for TypedSurface< colorDepth >:
Inheritance graph
[legend]

Public Member Functions

 TypedSurface (SDL_Surface *surface)
 
 TypedSurface (SDLmm::Surface &surface, int depthCheck)
 the parameter depthcheck is primarily there to prevent accidential usage of this constructor More...
 
 TypedSurface (const TypedSurface< colorDepth > &other)
 
 TypedSurface ()
 
- Public Member Functions inherited from Surface
 Surface (SDL_Surface *surface)
 
 Surface (const SDLmm::Surface &other)
 
 Surface ()
 
Surface Duplicate () const
 
void newFromBGI (void *img)
 Creates an image from an BGI image structure. More...
 
void * toBGI () const
 
void FillTransparent ()
 
void read (tnstream &stream)
 
void readImageFile (tnstream &stream)
 
void write (tnstream &stream) const
 
void strech (int width, int height)
 
void writeDefaultPixelFormat (tnstream &stream)
 
void assignDefaultPalette ()
 assigns the default ASC palette to the surface (only for 8 Bit surfaces) More...
 
void assignPalette (SDL_Color *colors, int startColor=0, int colorNum=256)
 
void detectColorKey (bool RLE=false)
 tries to automatically detect the color key of the surface More...
 
bool isTransparent (SDLmm::Color col) const
 
void ColorKey2AlphaChannel ()
 
bool hasAlpha ()
 
int getMemoryFootprint () const
 
SDL_Surface * getBaseSurface ()
 
const SDL_Surface * getBaseSurface () const
 
 ~Surface ()
 

Static Public Attributes

static const int depth = colorDepth
 
- Static Public Attributes inherited from Surface
static const Uint32 transparent = 0
 
static const Uint32 opaque = 255l
 

Protected Member Functions

virtual int getDepthFormat ()
 
- Protected Member Functions inherited from TypedSurfaceBase
 TypedSurfaceBase (SDL_Surface *surface)
 
 TypedSurfaceBase (const SDLmm::Surface &other)
 
 TypedSurfaceBase ()
 
- Protected Member Functions inherited from Surface
void convert ()
 

Additional Inherited Members

- Static Public Member Functions inherited from Surface
static Surface createSurface (int width, int height, SDLmm::Color color=255)
 
static Surface createSurface (int width, int height, int depth, SDLmm::Color color=0xff0000ff)
 
static Surface Wrap (SDL_Surface *surface)
 
static void SetScreen (SDL_Surface *screen)
 
static void readDefaultPixelFormat (tnstream &stream)
 

Detailed Description

template<int colorDepth>
class TypedSurface< colorDepth >

Definition at line 136 of file surface.h.

Constructor & Destructor Documentation

template<int colorDepth>
TypedSurface< colorDepth >::TypedSurface ( SDL_Surface *  surface)
inlineexplicit

Definition at line 139 of file surface.h.

template<int colorDepth>
TypedSurface< colorDepth >::TypedSurface ( SDLmm::Surface &  surface,
int  depthCheck 
)
inlineexplicit

the parameter depthcheck is primarily there to prevent accidential usage of this constructor

Definition at line 142 of file surface.h.

References TypedSurface< colorDepth >::depth.

template<int colorDepth>
TypedSurface< colorDepth >::TypedSurface ( const TypedSurface< colorDepth > &  other)
inline

Definition at line 147 of file surface.h.

template<int colorDepth>
TypedSurface< colorDepth >::TypedSurface ( )
inline

Definition at line 148 of file surface.h.

Member Function Documentation

template<int colorDepth>
virtual int TypedSurface< colorDepth >::getDepthFormat ( )
inlineprotectedvirtual

Reimplemented from Surface.

Definition at line 150 of file surface.h.

References TypedSurface< colorDepth >::depth.

Member Data Documentation

template<int colorDepth>
const int TypedSurface< colorDepth >::depth = colorDepth
static

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