diff options
Diffstat (limited to 'apps/plugins/lua/include_lua/color.lua')
-rw-r--r-- | apps/plugins/lua/include_lua/color.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/plugins/lua/include_lua/color.lua b/apps/plugins/lua/include_lua/color.lua index fd321edd9d..7266c090f3 100644 --- a/apps/plugins/lua/include_lua/color.lua +++ b/apps/plugins/lua/include_lua/color.lua @@ -44,7 +44,7 @@ local _clr = {} do local _NIL = nil -- _NIL placeholder local maxstate = (bit.lshift(1, rb.LCD_DEPTH) - 1) - + if rb.LCD_DEPTH > 24 then -- no alpha channels maxstate = (bit.lshift(1, 24) - 1) end @@ -89,7 +89,7 @@ local _clr = {} do r, g, b = (r or 0), (g or 0), (b or 0) ru = ru + r; gu = gu + g; bu = bu + b else - ru = ru + inc; gu = gu + inc; bu = bu + inc + ru = ru + inc; gu = gu + inc; bu = bu + inc end color = rb.lcd_rgbpack(ru, gu, bu) |