MCPcopy Create free account
hub / github.com/CruiserOne/Astrolog / BmpSetAll

Function BmpSetAll

xdevice.cpp:293–306  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

291// Set all pixels in a 24 bit bitmap to the specified RGB color value.
292
293void BmpSetAll(Bitmap *b, KV kv)
294{
295 int x, y, nR, nG, nB;
296 byte *pb;
297
298 nR = RgbR(kv); nG = RgbG(kv); nB = RgbB(kv);
299 for (y = 0; y < b->y; y++) {
300 pb = _PbXY(b, 0, y);
301 for (x = 0; x < b->x; x++) {
302 _SetRGB(pb, nR, nG, nB);
303 pb += cbPixelK;
304 }
305 }
306}
307
308
309// Copy a rectangle from one bitmap structure to a different rectangle in

Callers 2

FBmpDrawMapFunction · 0.85
FBmpDrawMap2Function · 0.85

Calls 2

_PbXYFunction · 0.85
_SetRGBFunction · 0.85

Tested by

no test coverage detected