|
Estella 0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
|
Row arithmetic shared by the backends' texture uploads. More...
Go to the source code of this file.
Namespaces | |
| namespace | esengine |
Functions | |
| void | esengine::stageTextureRows (u8 *dst, const u8 *src, u32 width, u32 height, u32 srcBpp, u32 dstBpp, bool reverseRows) |
Row arithmetic shared by the backends' texture uploads.
A backend's texel size need not match the layout the caller allocated (WebGPU has no 3-channel format, so RGB8 sources land in RGBA8 textures). Sizing a read of caller-owned pixels with the DESTINATION row is an out-of-bounds read, so the conversion lives here, in one testable place, rather than inline in each backend.
Definition in file PixelUpload.hpp.