更新 api.h

对这个GL_RGB_16_to_32(rgb)宏修改,增加透明度a,这样当需要32位色时透明度a时,draw_bitmap()才能显示出bitmap。
This commit is contained in:
Zzzz 2019-05-11 12:41:49 +08:00
parent ad9bbe926b
commit b7cb15c0da
1 changed files with 1 additions and 1 deletions

View File

@ -23,7 +23,7 @@ void log_out(const char* log);
#define GL_RGB_G(rgb) ((((unsigned int)(rgb)) >> 8) & 0xFF)
#define GL_RGB_B(rgb) (((unsigned int)(rgb)) & 0xFF)
#define GL_RGB_32_to_16(rgb) (((((unsigned int)(rgb)) & 0xFF) >> 3) | ((((unsigned int)(rgb)) & 0xFC00) >> 5) | ((((unsigned int)(rgb)) & 0xF80000) >> 8))
#define GL_RGB_16_to_32(rgb) (((((unsigned int)(rgb)) & 0x1F) << 3) | ((((unsigned int)(rgb)) & 0x7E0) << 5) | ((((unsigned int)(rgb)) & 0xF800) << 8))
#define GL_RGB_16_to_32(rgb) ((0xFF << 24) | ((((unsigned int)(rgb)) & 0x1F) << 3) | ((((unsigned int)(rgb)) & 0x7E0) << 5) | ((((unsigned int)(rgb)) & 0xF800) << 8))
typedef struct _T_TIME
{