OpenMortal Apocalypse mirror
Sourceforge mirror
SourceForge.net Logo
      News | Info | Characters | Arenas | Screenshots | Forums | Download  
Developer: Making of | Toplevel design | Character-HOWTO | AI Design | Submit a Character
Documentation: Main Page | Modules | Class Hierarchy | Class List | File List

sge_surface.cpp File Reference

#include "SDL.h"
#include <math.h>
#include <string.h>
#include <stdarg.h>
#include "sge_surface.h"

Functions

void sge_Update_OFF (void)
 Misc.
void sge_Update_ON (void)
void sge_Lock_OFF (void)
void sge_Lock_ON (void)
Uint8 sge_getUpdate (void)
Uint8 sge_getLock (void)
void sge_UpdateRect (SDL_Surface *screen, Sint16 x, Sint16 y, Uint16 w, Uint16 h)
SDL_Surface * sge_CreateAlphaSurface (Uint32 flags, int width, int height)
Uint32 sge_MapAlpha (Uint8 R, Uint8 G, Uint8 B, Uint8 A)
void sge_SetError (const char *format,...)
void _PutPixel (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
 Pixel functions *.
void _PutPixel (SDL_Surface *surface, Sint16 x, Sint16 y, Uint8 R, Uint8 G, Uint8 B)
void _PutPixel8 (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
void _PutPixel16 (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
void _PutPixel24 (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
void _PutPixel32 (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
void _PutPixelX (SDL_Surface *dest, Sint16 x, Sint16 y, Uint32 color)
void sge_PutPixel (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color)
void sge_PutPixel (SDL_Surface *surface, Sint16 x, Sint16 y, Uint8 R, Uint8 G, Uint8 B)
Sint32 sge_CalcYPitch (SDL_Surface *dest, Sint16 y)
void sge_pPutPixel (SDL_Surface *surface, Sint16 x, Sint32 ypitch, Uint32 color)
Uint32 sge_GetPixel (SDL_Surface *surface, Sint16 x, Sint16 y)
void _PutPixelAlpha (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color, Uint8 alpha)
void sge_PutPixelAlpha (SDL_Surface *surface, Sint16 x, Sint16 y, Uint32 color, Uint8 alpha)
void _PutPixelAlpha (SDL_Surface *surface, Sint16 x, Sint16 y, Uint8 R, Uint8 G, Uint8 B, Uint8 alpha)
void sge_PutPixelAlpha (SDL_Surface *surface, Sint16 x, Sint16 y, Uint8 R, Uint8 G, Uint8 B, Uint8 alpha)
void sge_write_block8 (SDL_Surface *Surface, Uint8 *block, Sint16 y)
 Block functions *.
void sge_write_block16 (SDL_Surface *Surface, Uint16 *block, Sint16 y)
void sge_write_block32 (SDL_Surface *Surface, Uint32 *block, Sint16 y)
void sge_read_block8 (SDL_Surface *Surface, Uint8 *block, Sint16 y)
void sge_read_block16 (SDL_Surface *Surface, Uint16 *block, Sint16 y)
void sge_read_block32 (SDL_Surface *Surface, Uint32 *block, Sint16 y)
void sge_ClearSurface (SDL_Surface *Surface, Uint32 color)
 Blitting/surface functions *.
void sge_ClearSurface (SDL_Surface *Surface, Uint8 R, Uint8 G, Uint8 B)
int sge_BlitTransparent (SDL_Surface *Src, SDL_Surface *Dest, Sint16 SrcX, Sint16 SrcY, Sint16 DestX, Sint16 DestY, Sint16 W, Sint16 H, Uint32 Clear, Uint8 Alpha)
int sge_Blit (SDL_Surface *Src, SDL_Surface *Dest, Sint16 SrcX, Sint16 SrcY, Sint16 DestX, Sint16 DestY, Sint16 W, Sint16 H)
SDL_Surface * sge_copy_surface (SDL_Surface *src)
SDL_Surface * sge_copy_surface (SDL_Surface *a_poSource, Sint16 x, Sint16 y, Sint16 w, Sint16 h)
SDL_Color sge_FillPaletteEntry (Uint8 R, Uint8 G, Uint8 B)
 Palette functions *.
SDL_Color sge_GetRGB (SDL_Surface *Surface, Uint32 Color)
void sge_Fader (SDL_Surface *Surface, Uint8 sR, Uint8 sG, Uint8 sB, Uint8 dR, Uint8 dG, Uint8 dB, Uint32 *ctab, int start, int stop)
void sge_AlphaFader (Uint8 sR, Uint8 sG, Uint8 sB, Uint8 sA, Uint8 dR, Uint8 dG, Uint8 dB, Uint8 dA, Uint32 *ctab, int start, int stop)
void sge_SetupRainbowPalette (SDL_Surface *Surface, Uint32 *ctab, int intensity, int start, int stop)
void sge_SetupBWPalette (SDL_Surface *Surface, Uint32 *ctab, int start, int stop)

Variables

Uint8 _sge_update = 1
Uint8 _sge_lock = 1

Function Documentation

void _PutPixel SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint8  R,
Uint8  G,
Uint8  B
 

void _PutPixel SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

Pixel functions *.

void _PutPixel16 SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

void _PutPixel24 SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

void _PutPixel32 SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

void _PutPixel8 SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

void _PutPixelAlpha SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint8  R,
Uint8  G,
Uint8  B,
Uint8  alpha
 

void _PutPixelAlpha SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color,
Uint8  alpha
 

void _PutPixelX SDL_Surface *  dest,
Sint16  x,
Sint16  y,
Uint32  color
 

void sge_AlphaFader Uint8  sR,
Uint8  sG,
Uint8  sB,
Uint8  sA,
Uint8  dR,
Uint8  dG,
Uint8  dB,
Uint8  dA,
Uint32 *  ctab,
int  start,
int  stop
 

int sge_Blit SDL_Surface *  Src,
SDL_Surface *  Dest,
Sint16  SrcX,
Sint16  SrcY,
Sint16  DestX,
Sint16  DestY,
Sint16  W,
Sint16  H
 

int sge_BlitTransparent SDL_Surface *  Src,
SDL_Surface *  Dest,
Sint16  SrcX,
Sint16  SrcY,
Sint16  DestX,
Sint16  DestY,
Sint16  W,
Sint16  H,
Uint32  Clear,
Uint8  Alpha
 

Sint32 sge_CalcYPitch SDL_Surface *  dest,
Sint16  y
 

void sge_ClearSurface SDL_Surface *  Surface,
Uint8  R,
Uint8  G,
Uint8  B
 

void sge_ClearSurface SDL_Surface *  Surface,
Uint32  color
 

Blitting/surface functions *.

SDL_Surface* sge_copy_surface SDL_Surface *  a_poSource,
Sint16  x,
Sint16  y,
Sint16  w,
Sint16  h
 

SDL_Surface* sge_copy_surface SDL_Surface *  src  ) 
 

SDL_Surface* sge_CreateAlphaSurface Uint32  flags,
int  width,
int  height
 

void sge_Fader SDL_Surface *  Surface,
Uint8  sR,
Uint8  sG,
Uint8  sB,
Uint8  dR,
Uint8  dG,
Uint8  dB,
Uint32 *  ctab,
int  start,
int  stop
 

SDL_Color sge_FillPaletteEntry Uint8  R,
Uint8  G,
Uint8  B
 

Palette functions *.

Uint8 sge_getLock void   ) 
 

Uint32 sge_GetPixel SDL_Surface *  surface,
Sint16  x,
Sint16  y
 

SDL_Color sge_GetRGB SDL_Surface *  Surface,
Uint32  Color
 

Uint8 sge_getUpdate void   ) 
 

void sge_Lock_OFF void   ) 
 

void sge_Lock_ON void   ) 
 

Uint32 sge_MapAlpha Uint8  R,
Uint8  G,
Uint8  B,
Uint8  A
 

void sge_pPutPixel SDL_Surface *  surface,
Sint16  x,
Sint32  ypitch,
Uint32  color
 

void sge_PutPixel SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint8  R,
Uint8  G,
Uint8  B
 

void sge_PutPixel SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color
 

void sge_PutPixelAlpha SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint8  R,
Uint8  G,
Uint8  B,
Uint8  alpha
 

void sge_PutPixelAlpha SDL_Surface *  surface,
Sint16  x,
Sint16  y,
Uint32  color,
Uint8  alpha
 

void sge_read_block16 SDL_Surface *  Surface,
Uint16 *  block,
Sint16  y
 

void sge_read_block32 SDL_Surface *  Surface,
Uint32 *  block,
Sint16  y
 

void sge_read_block8 SDL_Surface *  Surface,
Uint8 *  block,
Sint16  y
 

void sge_SetError const char *  format,
  ...
 

void sge_SetupBWPalette SDL_Surface *  Surface,
Uint32 *  ctab,
int  start,
int  stop
 

void sge_SetupRainbowPalette SDL_Surface *  Surface,
Uint32 *  ctab,
int  intensity,
int  start,
int  stop
 

void sge_Update_OFF void   ) 
 

Misc.

functions *

void sge_Update_ON void   ) 
 

void sge_UpdateRect SDL_Surface *  screen,
Sint16  x,
Sint16  y,
Uint16  w,
Uint16  h
 

void sge_write_block16 SDL_Surface *  Surface,
Uint16 *  block,
Sint16  y
 

void sge_write_block32 SDL_Surface *  Surface,
Uint32 *  block,
Sint16  y
 

void sge_write_block8 SDL_Surface *  Surface,
Uint8 *  block,
Sint16  y
 

Block functions *.


Variable Documentation

Uint8 _sge_lock = 1
 

Uint8 _sge_update = 1