class csGraphics2D This is the base class for 2D renderer
This is the base class for 2D renderer. System-dependent ports should derive their own SysGraphics2D class from this one and implement required (marked with an asterisk (*)) functions. Functions not marked with an asterisk are optional, but possibly slow since they are too general.
static csPixelFormat pfmt
static unsigned char* Memory
static int* LineAddress
static ISystem* system
static int Font
static int Width
static bool FullScreen
static RGBpaletteEntry Palette[256]
static bool PaletteAlloc[256]
csGraphics2D(ISystem* piSystem)
virtual ~csGraphics2D()
virtual void Initialize()
virtual bool Open(char *Title)
virtual void Close()
virtual void SetClipRect(int xmin, int ymin, int xmax, int ymax)
virtual void GetClipRect(int &xmin, int &ymin, int &xmax, int &ymax)
virtual bool BeginDraw()
virtual void FinishDraw()
virtual void Print(csRect *area = NULL)
virtual int GetPage()
virtual bool DoubleBuffer(bool Enable)
virtual bool DoubleBuffer()
void ClearAll(int color)
virtual void Clear(int color)
static void (*DrawPixel)(int x, int y, int color)
virtual void DrawLine(float x1, float y1, float x2, float y2, int color)
virtual void DrawBox(int x, int y, int w, int h, int color)
virtual void SetRGB(int i, int r, int g, int b)
virtual void Write(int x, int y, int fg, int bg, char *text)
static void (*WriteChar)(int x, int y, int fg, int bg, char c)
virtual int GetTextWidth(int Font, char *text)
virtual int GetTextHeight(int Font)
static void (*DrawSprite)(ITextureHandle *hTex, int sx, int sy, int sw, int sh, int tx, int ty, int tw, int th)
static unsigned char* (*GetPixelAt)(int x, int y)
int GetNumPalEntries()
int GetPixelBytes()
csPixelFormat* GetPixelFormat()
virtual bool SaveArea(ImageArea *&Area, int x, int y, int w, int h)
virtual void RestoreArea(ImageArea *Area, bool Free = true)
virtual void FreeArea(ImageArea *Area)
static bool ClipLine(float &x1, float &y1, float &x2, float &y2, int xmin, int ymin, int xmax, int ymax)
virtual bool SetMousePosition(int x, int y)
virtual bool SetMouseCursor(int iShape, ITextureHandle *hBitmap)
virtual bool PerformExtension(char* args)
void SysPrintf(int mode, char* text, ...)
virtual void GetStringError(HRESULT hRes, char* szValue)
void complete_pixel_format()
static void DrawPixel8(int x, int y, int color)
static void WriteChar8(int x, int y, int fg, int bg, char c)
static unsigned char* GetPixelAt8(int x, int y)
static void DrawSprite8(ITextureHandle *hTex, int sx, int sy, int sw, int sh, int tx, int ty, int tw, int th)
static void DrawPixel16(int x, int y, int color)
static void WriteChar16(int x, int y, int fg, int bg, char c)
static unsigned char* GetPixelAt16(int x, int y)
static void DrawSprite16(ITextureHandle *hTex, int sx, int sy, int sw, int sh, int tx, int ty, int tw, int th)
static void DrawPixel32(int x, int y, int color)
static void WriteChar32(int x, int y, int fg, int bg, char c)
static unsigned char* GetPixelAt32(int x, int y)
static void DrawSprite32(ITextureHandle *hTex, int sx, int sy, int sw, int sh, int tx, int ty, int tw, int th)
this page has been generated automatically by doc++
(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de