mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-09-24 00:54:18 +08:00
new surface pixel format for main window: ST_PIXEL_XRGB565
This commit is contained in:
+2
-1
@@ -6916,13 +6916,14 @@ static inline BOOL MainWindowThreadCleanup (HWND hMainWnd)
|
||||
#define ST_PIXEL_ARGB4444 0x0001
|
||||
#define ST_PIXEL_ARGB1555 0x0002
|
||||
#define ST_PIXEL_ARGB8888 0x0003
|
||||
#define ST_PIXEL_XRGB565 0x0004
|
||||
|
||||
/* other flags for future use */
|
||||
|
||||
/* for default surface flags */
|
||||
#define ST_DEFAULT (ST_PIXEL_DEFAULT)
|
||||
|
||||
#define CT_SYSTEM_MASK 0X0000FF
|
||||
#define CT_SYSTEM_MASK 0x0000FF
|
||||
#define CT_OPAQUE 0x000000
|
||||
#define CT_COLORKEY 0x000001
|
||||
#define CT_ALPHACHANNEL 0x000002
|
||||
|
||||
@@ -631,6 +631,7 @@ GAL_Surface *GAL_CreateSharedRGBSurface (GAL_VideoDevice* video,
|
||||
#define ST_PIXEL_ARGB4444 0x0001
|
||||
#define ST_PIXEL_ARGB1555 0x0002
|
||||
#define ST_PIXEL_ARGB8888 0x0003
|
||||
#define ST_PIXEL_XRGB565 0x0004
|
||||
#endif /* not define ST_PIXEL_MASK */
|
||||
|
||||
/* Allocate a shared RGB surface from the current video device. */
|
||||
|
||||
@@ -558,6 +558,14 @@ GAL_Surface *GAL_CreateSurfaceForZNode (unsigned surf_flag, int width, int heigh
|
||||
Bmask = 0x000000FF;
|
||||
break;
|
||||
|
||||
case ST_PIXEL_XRGB565:
|
||||
bpp = 16;
|
||||
Amask = 0x0000;
|
||||
Rmask = 0xF800;
|
||||
Gmask = 0x07E0;
|
||||
Bmask = 0x001F;
|
||||
break;
|
||||
|
||||
default:
|
||||
bpp = __gal_screen->format->BitsPerPixel;
|
||||
Amask = __gal_screen->format->Amask;
|
||||
|
||||
Reference in New Issue
Block a user