mirror of
https://github.com/dankamongmen/notcurses.git
synced 2024-11-02 09:40:15 +00:00
fix cel_rgb_get[bf]b() #40
This commit is contained in:
parent
4426ef0574
commit
02b30c822e
@ -449,7 +449,7 @@ cell_rgb_blue(uint32_t rgb){
|
||||
|
||||
static inline void
|
||||
cell_rgb_get_fg(uint64_t channels, unsigned* r, unsigned* g, unsigned* b){
|
||||
uint32_t fg = ((channels & CELL_FG_MASK));
|
||||
uint32_t fg = ((channels & CELL_FG_MASK) >> 32u);
|
||||
*r = cell_rgb_red(fg);
|
||||
*g = cell_rgb_green(fg);
|
||||
*b = cell_rgb_blue(fg);
|
||||
@ -457,7 +457,7 @@ cell_rgb_get_fg(uint64_t channels, unsigned* r, unsigned* g, unsigned* b){
|
||||
|
||||
static inline void
|
||||
cell_rgb_get_bg(uint64_t channels, unsigned* r, unsigned* g, unsigned* b){
|
||||
uint32_t bg = ((channels & CELL_BG_MASK) >> 32u);
|
||||
uint32_t bg = ((channels & CELL_BG_MASK));
|
||||
*r = cell_rgb_red(bg);
|
||||
*g = cell_rgb_green(bg);
|
||||
*b = cell_rgb_blue(bg);
|
||||
|
Loading…
Reference in New Issue
Block a user