forked from Makuna/NeoPixelBus
mask byte not nibble (#701)
This commit is contained in:
1 parent
6ad69a8914
commit
b1b71920f0
3 files changed
+10
-10
No files matched your search
@@ -35,11 +35,11 @@ public:
|
||||
|
||||
// due to endianness the byte order must be copied to output
|
||||
*p++ = color.G >> 8;
|
||||
*p++ = color.G & 0x0f;
|
||||
*p++ = color.G & 0xff;
|
||||
*p++ = color.R >> 8;
|
||||
*p++ = color.R & 0x0f;
|
||||
*p++ = color.R & 0xff;
|
||||
*p++ = color.B >> 8;
|
||||
*p = color.B & 0x0f;
|
||||
*p = color.B & 0xff;
|
||||
}
|
||||
|
||||
static ColorObject retrievePixelColor(const uint8_t* pPixels, uint16_t indexPixel)
|
||||
|
||||
@@ -35,11 +35,11 @@ public:
|
||||
|
||||
// due to endianness the byte order must be copied to output
|
||||
*p++ = color.R >> 8;
|
||||
*p++ = color.R & 0x0f;
|
||||
*p++ = color.R & 0xff;
|
||||
*p++ = color.G >> 8;
|
||||
*p++ = color.G & 0x0f;
|
||||
*p++ = color.G & 0xff;
|
||||
*p++ = color.B >> 8;
|
||||
*p = color.B & 0x0f;
|
||||
*p = color.B & 0xff;
|
||||
}
|
||||
|
||||
static ColorObject retrievePixelColor(const uint8_t* pPixels, uint16_t indexPixel)
|
||||
|
||||
@@ -36,13 +36,13 @@ public:
|
||||
|
||||
// due to endianness the byte order must be copied to output
|
||||
*p++ = color.R >> 8;
|
||||
*p++ = color.R & 0x0f;
|
||||
*p++ = color.R & 0xff;
|
||||
*p++ = color.G >> 8;
|
||||
*p++ = color.G & 0x0f;
|
||||
*p++ = color.G & 0xff;
|
||||
*p++ = color.B >> 8;
|
||||
*p++ = color.B & 0x0f;
|
||||
*p++ = color.B & 0xff;
|
||||
*p++ = color.W >> 8;
|
||||
*p = color.W & 0x0f;
|
||||
*p = color.W & 0xff;
|
||||
}
|
||||
|
||||
static ColorObject retrievePixelColor(const uint8_t* pPixels, uint16_t indexPixel)
|
||||
|
||||
Reference in new issue
Block a user