FormIt C++ API  v23.0.0 (2023.0.0)
FormIt::Utils Namespace Reference

Classes

struct  Span
 Provides a "view" into a container/array. More...
 
class  UtilsImage
 FormIt::Utils::UtilsImage class. More...
 

Typedefs

using Guid = 1::array< uint8_t, 16 >
 

Functions

Guid NewGuid ()
 NewGuid() function. More...
 
Guid GuidFromString (const 1::string &str)
 GuidFromString() function. More...
 
::string GuidToHexString (const Guid &guid)
 GuidToHexString() function. More...
 
FORMIT_CORE_EXPORT::string CreateTextureFileFromData (const 1::vector< char > &data, const 1::string &fileName, bool bForceRemake=false)
 Create the texture cache file from a texture's bit data. More...
 
FORMIT_CORE_EXPORT::shared_ptr< FormIt::Utils::UtilsImageLoadImageData (const 1::string &aRootFolder, const 1::string &filename, bool swapredblue=false, bool flip=false)
 Create an Image object from an input file (JPEG or PNG) More...
 
FORMIT_CORE_EXPORT::shared_ptr< FormIt::Utils::UtilsImageDecodeImage (unsigned char *data, int size, bool swapredblue=false, bool flip=false)
 Create an Image object from input image data (JPEG or PNG format) More...
 
FORMIT_CORE_EXPORT::vector< unsigned char > EncodeImagePNG (1::vector< unsigned char > &imgData, size_t width, size_t height, size_t bytesPerPixel)
 Create PNG formatted data from raw rgb (bytesPerPixel == 3) or rgba (bytesPerPixel == 4) pixel data. More...
 
FORMIT_CORE_EXPORT::vector< char > EncodeImageJPG (unsigned char *imageData, size_t image_width, size_t image_height, size_t bytesPerPixel, bool encodeAlphaOnly, int quality=80)
 Create JPG formatted data from raw rgb (bytesPerPixel == 3) or rgba (bytesPerPixel == 4) pixel data. More...
 

Typedef Documentation

using FormIt::Utils::Guid = typedef 1::array<uint8_t, 16>