|
ESPHome 2026.9.0-dev
|
Data Structures | |
| class | BmpDecoder |
| Image decoder specialization for BMP images. More... | |
| class | ImageDecoder |
| Class to abstract decoding different image formats. More... | |
| class | JpegDecoder |
| Image decoder specialization for JPEG images. More... | |
| class | PngDecoder |
| Image decoder specialization for PNG images. More... | |
| class | QoiDecoder |
| Image decoder specialization for QOI images. More... | |
| class | RuntimeImage |
| A dynamic image that can be loaded and decoded at runtime. More... | |
Enumerations | |
| enum | DecodeError : int { DECODE_ERROR_INVALID_TYPE = -1 , DECODE_ERROR_UNSUPPORTED_FORMAT = -2 , DECODE_ERROR_OUT_OF_MEMORY = -3 , DECODE_ERROR_INTERNAL_DECODER_ERROR = -4 } |
| enum | ImageFormat { AUTO , BMP , JPEG , PNG , QOI } |
| Image format types that can be decoded dynamically. More... | |
Functions | |
| constexpr const char * | decode_error_to_string (int error) |
| const char * | get_mime_type_for_format (ImageFormat format) |
| Canonical MIME type for a format; "image/*" for AUTO/unknown. | |
| std::optional< ImageFormat > | get_format_for_mime_type (const char *mime_type) |
| Case-insensitive substring match of known media types; nullopt if none found. | |
| size_t | qoi_color_table_index (const Color &color) |
| bool | is_color_on (const Color &color) |
Variables | |
| constexpr uint8_t | QOI_OP_RGB = 0b11111110 |
| constexpr uint8_t | QOI_OP_RGBA = 0b11111111 |
| constexpr uint8_t | QOI_OP_INDEX = 0b00000000 |
| constexpr uint8_t | QOI_OP_DIFF = 0b01000000 |
| constexpr uint8_t | QOI_OP_LUMA = 0b10000000 |
| constexpr uint8_t | QOI_OP_RUN = 0b11000000 |
| constexpr uint8_t | QOI_RGB_CHUNK_SIZE = 4 |
| constexpr uint8_t | QOI_RGBA_CHUNK_SIZE = 5 |
| constexpr uint8_t | QOI_LUMA_CHUNK_SIZE = 2 |
| constexpr uint8_t | QOI_MASK_OP = 0b11000000 |
| constexpr uint8_t | QOI_MASK_VALUE = 0b00111111 |
| constexpr size_t | QOI_HEADER_SIZE = 14 |
| constexpr size_t | QOI_COLOR_TABLE_SIZE = 64 |
| enum esphome::runtime_image::DecodeError : int |
| Enumerator | |
|---|---|
| DECODE_ERROR_INVALID_TYPE | |
| DECODE_ERROR_UNSUPPORTED_FORMAT | |
| DECODE_ERROR_OUT_OF_MEMORY | |
| DECODE_ERROR_INTERNAL_DECODER_ERROR | |
Definition at line 7 of file image_decoder.h.
Image format types that can be decoded dynamically.
| Enumerator | |
|---|---|
| AUTO | Format is supplied per decode, e.g. detected from the Content-Type header by online_image; sniffing the image data is not implemented. |
| BMP | BMP format. |
| JPEG | JPEG format. |
| PNG | PNG format. |
| QOI | QOI format. |
Definition at line 10 of file image_format.h.
|
constexpr |
Definition at line 14 of file image_decoder.h.
| std::optional< ImageFormat > esphome::runtime_image::get_format_for_mime_type | ( | const char * | mime_type | ) |
Case-insensitive substring match of known media types; nullopt if none found.
Definition at line 38 of file image_format.cpp.
| const char * esphome::runtime_image::get_mime_type_for_format | ( | ImageFormat | format | ) |
Canonical MIME type for a format; "image/*" for AUTO/unknown.
Definition at line 29 of file image_format.cpp.
|
inline |
Definition at line 33 of file runtime_image.cpp.
|
inline |
Definition at line 32 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 30 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 29 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 24 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 26 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 27 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 18 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 17 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 19 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 15 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 16 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 20 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 22 of file qoi_decoder.cpp.
|
constexpr |
Definition at line 23 of file qoi_decoder.cpp.