3#include <CesiumImage/Library.h>
60 size_t targetRowStride,
61 const std::byte* pSource,
62 size_t sourceRowStride,
65 size_t bytesPerPixel);
A collection of utility functions for image manipulation operations.
static void unsafeBlitImage(std::byte *pTarget, size_t targetRowStride, const std::byte *pSource, size_t sourceRowStride, size_t sourceWidth, size_t sourceHeight, size_t bytesPerPixel)
Directly copies pixels from a source to a target, without validating the provided pointers or ranges.
static void savePng(const ImageAsset &image, std::vector< std::byte > &output)
Saves an image to an existing byte buffer in PNG format.
static std::vector< std::byte > savePng(const ImageAsset &image)
Saves an image to a new byte buffer in PNG format.
static bool blitImage(ImageAsset &target, const PixelRectangle &targetPixels, const ImageAsset &source, const PixelRectangle &sourcePixels)
Copies pixels from a source image to a target image.
Classes that support reading, decoding, and manipulating images.
A 2D image asset, including its pixel data. The image may have mipmaps, and it may be encoded in a GP...
Specifies a rectangle of pixels in an image.
int32_t x
The X coordinate of the top-left corner of the rectangle.
int32_t height
The total number of pixels in the vertical direction.
int32_t width
The total number of pixels in the horizontal direction.
int32_t y
The Y coordinate of the top-left corner of the rectangle.