MCPcopy Create free account
hub / github.com/android/ndk-samples / make565

Function make565

bitmap-plasma/app/src/main/cpp/plasma.cpp:125–128  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

123static uint16_t palette[PALETTE_SIZE];
124
125static uint16_t make565(int red, int green, int blue) {
126 return (uint16_t)(((red << 8) & 0xf800) | ((green << 3) & 0x07e0) |
127 ((blue >> 3) & 0x001f));
128}
129
130static void init_palette(void) {
131 int nn, mm = 0;

Callers 1

init_paletteFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected