Lines Matching refs:surface
66 static bool inline cRasterTranslucentRle(SwSurface* surface, const SwRle* rle, uint8_t r, uint8_t g… in cRasterTranslucentRle() argument
71 if (surface->channelSize == sizeof(uint32_t)) { in cRasterTranslucentRle()
72 auto color = surface->join(r, g, b, a); in cRasterTranslucentRle()
75 auto dst = &surface->buf32[span->y * surface->stride + span->x]; in cRasterTranslucentRle()
84 } else if (surface->channelSize == sizeof(uint8_t)) { in cRasterTranslucentRle()
87 auto dst = &surface->buf8[span->y * surface->stride + span->x]; in cRasterTranslucentRle()
100 static bool inline cRasterTranslucentRect(SwSurface* surface, const SwBBox& region, uint8_t r, uint… in cRasterTranslucentRect() argument
106 if (surface->channelSize == sizeof(uint32_t)) { in cRasterTranslucentRect()
107 auto color = surface->join(r, g, b, a); in cRasterTranslucentRect()
108 auto buffer = surface->buf32 + (region.min.y * surface->stride) + region.min.x; in cRasterTranslucentRect()
111 auto dst = &buffer[y * surface->stride]; in cRasterTranslucentRect()
117 } else if (surface->channelSize == sizeof(uint8_t)) { in cRasterTranslucentRect()
118 auto buffer = surface->buf8 + (region.min.y * surface->stride) + region.min.x; in cRasterTranslucentRect()
121 auto dst = &buffer[y * surface->stride]; in cRasterTranslucentRect()
131 static bool inline cRasterABGRtoARGB(RenderSurface* surface) in cRasterABGRtoARGB() argument
133 TVGLOG("SW_ENGINE", "Convert ColorSpace ABGR - ARGB [Size: %d x %d]", surface->w, surface->h); in cRasterABGRtoARGB()
136 if (surface->w % 2 == 0) { in cRasterABGRtoARGB()
137 auto buffer = reinterpret_cast<uint64_t*>(surface->buf32); in cRasterABGRtoARGB()
138 for (uint32_t y = 0; y < surface->h; ++y, buffer += surface->stride / 2) { in cRasterABGRtoARGB()
140 for (uint32_t x = 0; x < surface->w / 2; ++x, ++dst) { in cRasterABGRtoARGB()
148 auto buffer = surface->buf32; in cRasterABGRtoARGB()
149 for (uint32_t y = 0; y < surface->h; ++y, buffer += surface->stride) { in cRasterABGRtoARGB()
151 for (uint32_t x = 0; x < surface->w; ++x, ++dst) { in cRasterABGRtoARGB()
162 static bool inline cRasterARGBtoABGR(RenderSurface* surface) in cRasterARGBtoABGR() argument
165 return cRasterABGRtoARGB(surface); in cRasterARGBtoABGR()