00001 #ifndef TEXTRENDER
00002 #define TEXTRENDER
00003
00004 #include "type.h"
00005 #include "ssd192X.h"
00006
00007 void CharToCursorMem(int pMemOffset, int destWidth, const UINT8 iAsciiNum, int iXPos, int iYPos, int iInvert);
00008
00009 void StringToCursorMem(int pMemOffset, int destWidth, const char*str, int iXPos, int iYPos, int iInvert);
00010
00011 void CharTo16bppMem(UINT8 nFont,
00012 UINT32 memOffset,
00013 UINT16 byWidth,
00014 UINT8 bypp,
00015 SSDRGBAType *pfrColor,
00016 SSDRGBAType *pbkColor,
00017 UINT8 nChar,
00018 UINT8 *charWidthOut);
00019
00020 void MoveFontToSSD16bppMem(UINT8 nFont,
00021 UINT32 memOffset,
00022 UINT16 byWidth,
00023 UINT8 bypp,
00024 SSDRGBAType *pfrColor,
00025 SSDRGBAType *pbkColor);
00026
00027 UINT8 getFontWidth(UINT8 nFont);
00028 UINT8 getFontHeight(UINT8 nFont);
00029 UINT8 getFontChars(UINT8 nFont);
00030 UINT16 Get16bitColor(SSDRGBAType *pc);
00031
00032 typedef struct
00033 {
00034 unsigned char width;
00035 unsigned char height;
00036 unsigned char isProportional;
00037 unsigned char gliphs;
00038 } fontHeaderType;
00039
00040 void CurShapeToSSDMem(int pMemOffset);
00041
00042 void FontCharToPos(UINT8 nFont, UINT16 wndWidth, const char chIn, UINT8 bIsAscii, INT16 *px, INT16 *py, UINT8 *pCharWidth);
00043
00044 #endif