MCPcopy Create free account
hub / github.com/ZDoom/Raze / CopyPixelDataRGB

Method CopyPixelDataRGB

source/common/textures/bitmap.cpp:391–404  ·  view source on GitHub ↗

=========================================================================== True Color texture copy function ===========================================================================

Source from the content-addressed store, hash-verified

389//
390//===========================================================================
391void FBitmap::CopyPixelDataRGB(int originx, int originy, const uint8_t *patch, int srcwidth,
392 int srcheight, int step_x, int step_y, int rotate, int ct, FCopyInfo *inf,
393 int r, int g, int b)
394{
395 if (ClipCopyPixelRect(&ClipRect, originx, originy, patch, srcwidth, srcheight, step_x, step_y, rotate))
396 {
397 uint8_t *buffer = data + 4 * originx + Pitch * originy;
398 int op = inf==NULL? OP_COPY : inf->op;
399 for (int y=0;y<srcheight;y++)
400 {
401 copyfuncs[op][ct](&buffer[y*Pitch], &patch[y*step_y], srcwidth, step_x, inf, r, g, b);
402 }
403 }
404}
405
406template<class TDest, class TBlend>
407void iCopyPaletted(uint8_t *buffer, const uint8_t * patch, int srcwidth, int srcheight, int Pitch,

Callers 7

GetBgraBitmapMethod · 0.80
CopyPixelsMethod · 0.80
GetBgraBitmapMethod · 0.80
CopyPixelsMethod · 0.80
CopyPixelsMethod · 0.80
CopyPixelsMethod · 0.80
CopyPixelsMethod · 0.80

Calls 1

ClipCopyPixelRectFunction · 0.85

Tested by

no test coverage detected