An ImageFormatHandler implementation for reading and writing PNG image files.
More...
An ImageFormatHandler implementation for reading and writing PNG image files.
Definition at line 9 of file PNGImageFactory.h.
◆ canRead() [1/2]
| virtual bool PNGImageFactory::canRead |
( |
const File & | format | ) |
const |
|
overridevirtual |
Checks whether the given file can be read by this handler.
- Parameters
-
| [in] | format | The file to check. |
- Returns
- True if the file can be read.
Implements ImageFormatHandler.
◆ canRead() [2/2]
| virtual bool PNGImageFactory::canRead |
( |
StringView | format | ) |
const |
|
overridevirtual |
Checks whether the given format string can be read by this handler.
- Parameters
-
| [in] | format | The format string to check. |
- Returns
- True if the format can be read.
Implements ImageFormatHandler.
◆ canWrite()
| virtual bool PNGImageFactory::canWrite |
( |
StringView | format | ) |
const |
|
overridevirtual |
Checks whether the given format string can be written by this handler.
- Parameters
-
| [in] | format | The format string to check. |
- Returns
- True if the format can be written.
Implements ImageFormatHandler.
◆ compressionFormat()
Determines the compression format from raw image data.
- Parameters
-
| [in] | data | The raw image data. |
| [in] | size | The size of the data in bytes. |
- Returns
- The compression format identifier string.
Reimplemented from ImageFormatHandler.
◆ DefaultFactory()
Returns the singleton default PNGImageFactory instance.
- Returns
- A reference to the default factory.
◆ getCompressed()
Reads compressed data from a PNG image.
- Parameters
-
| [in] | data | The image cache data to populate. |
| [in] | format | The target compression format. |
- Returns
- True if data was read successfully.
Reimplemented from ImageFormatHandler.
◆ getMetaData()
Reads metadata from a PNG image.
- Parameters
-
| [in] | data | The image cache data to populate. |
- Returns
- True if metadata was read successfully.
Reimplemented from ImageFormatHandler.
◆ getSize()
Reads the image dimensions from a PNG file.
- Parameters
-
| [in] | data | The image cache data to populate with size. |
- Returns
- True if the size was read successfully.
Reimplemented from ImageFormatHandler.
◆ getSupportedFormats()
| virtual void PNGImageFactory::getSupportedFormats |
( |
AlocatingAlignedBuffer< FileFormat, 64 > & | formats, |
|
|
bool | is_read ) const |
|
overridevirtual |
Populates the buffer with supported image formats.
- Parameters
-
| [in] | formats | The buffer to populate. |
| [in] | is_read | Whether to list read formats (true) or write formats (false). |
Implements ImageFormatHandler.
◆ getUncompressed()
Reads uncompressed pixel data from a PNG image.
- Parameters
-
| [in] | data | The image cache data to populate. |
- Returns
- True if data was read successfully.
Reimplemented from ImageFormatHandler.
◆ hasTransparency()
Checks whether the PNG image has an alpha transparency channel.
- Parameters
-
| [in] | data | The image cache data to check. |
- Returns
- True if the image has transparency.
Reimplemented from ImageFormatHandler.
◆ id()
| virtual UUID PNGImageFactory::id |
( |
| ) |
const |
|
inlineoverridevirtual |
The documentation for this class was generated from the following file: