1
0
mirror of https://github.com/XProger/OpenLara.git synced 2025-08-11 23:54:09 +02:00

#15 fix 16 to 24-bit color conversion

This commit is contained in:
XProger
2017-04-08 01:02:45 +03:00
parent b5de93cd74
commit eac32f2cd5
2 changed files with 3 additions and 3 deletions

View File

@@ -175,8 +175,8 @@ namespace TR {
struct Color16 {
uint16 r:5, g:5, b:5, a:1;
operator Color24() const { return Color24(r << 3, g << 3, b << 3); }
operator Color32() const { return Color32(r << 3, g << 3, b << 3, -a); }
operator Color24() const { return Color24((r << 3) | (r >> 2), (g << 3) | (g >> 2), (b << 3) | (b >> 2)); }
operator Color32() const { return Color32((r << 3) | (r >> 2), (g << 3) | (g >> 2), (b << 3) | (b >> 2), -a); }
};
struct Vertex {