AuxiliaryImage Class
An image stored next to the primary image of a file: a thumbnail, a depth map, a gain map, a matte. It is borrowed from its AuxiliaryImageCollection, and decoded on demand by AuxiliaryImage.Decode.
public sealed class AuxiliaryImageProperties
| Name | Description |
|---|---|
| AuxiliaryType | Gets the type of an auxiliary image of a HEIC or AVIF file (the URN of its auxC property, such as urn:mpeg:hevc:2015:auxid:2 for a depth map), or null for an image that has none (a thumbnail, the gain map of a tone map item, an image of a JPEG file). |
| GainMapMetadata | Gets the parameters of a gain map, or null when the image is not a gain map, when the file does not give them (a gain map of Apple without ISO 21496-1 metadata), or when they cannot be read. |
| Kind | Gets what the image is. |
| Size | Gets the size of the image: for a HEIF item, after its clean aperture and before its orientation, as ImageInfo.Size (its ispe property when the item cannot be decoded); for a JPEG image, the size of its frame header. |
AuxiliaryType
AuxiliaryImage.csGets the type of an auxiliary image of a HEIC or AVIF file (the URN of its auxC property, such as urn:mpeg:hevc:2015:auxid:2 for a depth map), or null for an image that has none (a thumbnail, the gain map of a tone map item, an image of a JPEG file).
public string? AuxiliaryType { get; }Property value
GainMapMetadata
AuxiliaryImage.csGets the parameters of a gain map, or null when the image is not a gain map, when the file does not give them (a gain map of Apple without ISO 21496-1 metadata), or when they cannot be read.
public GainMapMetadata? GainMapMetadata { get; }Property value
Gets the size of the image: for a HEIF item, after its clean aperture and before its orientation, as ImageInfo.Size (its ispe property when the item cannot be decoded); for a JPEG image, the size of its frame header.
public Size Size { get; }Property value
Methods
| Name | Description |
|---|---|
| Decode(ImageDecodeOptions?) | Decodes the image. |
| Decode<TPixel>(ImageDecodeOptions?) | Decodes the image into a pixel format. |
| ToString() | Returns a string that represents the current object. |
Decode overloads
Decode(ImageDecodeOptions?)
AuxiliaryImage.csDecodes the image.
public Image Decode(ImageDecodeOptions? options = null)Parameters
optionsImageDecodeOptions?- The decoding options, or
nullfor the configuration the collection was loaded with.
Returns
Image A new image owned by the caller: a gain map, a depth map or a matte is usually a grayscale image, whose samples are the coded values.
Exceptions
InvalidImageContentException- The image is malformed.
UnsupportedImageFeatureException- The image uses a feature that is not supported.
ImageResourceLimitException- The image exceeds a resource limit.
Decode<TPixel>(ImageDecodeOptions?)
AuxiliaryImage.csDecodes the image into a pixel format.
public Image<TPixel> Decode<TPixel>(ImageDecodeOptions? options = null) where TPixel : unmanagedType parameters
TPixel- The pixel format.
Parameters
optionsImageDecodeOptions?- The decoding options, or
nullfor the configuration the collection was loaded with.
Returns
Image<TPixel> A new image owned by the caller.
Exceptions
NotSupportedExceptionTPixelis not a built-in pixel struct.InvalidImageContentException- The image is malformed.
UnsupportedImageFeatureException- The image uses a feature that is not supported, or cannot be converted to
TPixel. ImageResourceLimitException- The image exceeds a resource limit.