MediaFormat.MimetypeImageAvif Field
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
MIME type for AVIF still image data encoded in AV1.
[Android.Runtime.Register("MIMETYPE_IMAGE_AVIF", ApiSince=34)]
public const string MimetypeImageAvif;
[<Android.Runtime.Register("MIMETYPE_IMAGE_AVIF", ApiSince=34)>]
val mutable MimetypeImageAvif : string
Field Value
- Attributes
Remarks
MIME type for AVIF still image data encoded in AV1.
To decode such an image, MediaCodec
decoder for #MIMETYPE_VIDEO_AV1
shall be used. The client needs to form the correct #MediaFormat
based on additional information in the track format (shown in the next paragraph), and send it to MediaCodec#configure
.
The track's MediaFormat will come with #KEY_WIDTH
and #KEY_HEIGHT
keys, which describes the width and height of the image. If the image doesn't contain grid (i.e. none of #KEY_TILE_WIDTH
, #KEY_TILE_HEIGHT
, #KEY_GRID_ROWS
, #KEY_GRID_COLUMNS
are present), the track will contain a single sample of coded data for the entire image, and the image width and height should be used to set up the decoder.
If the image does come with grid, each sample from the track will contain one tile in the grid, of which the size is described by #KEY_TILE_WIDTH
and #KEY_TILE_HEIGHT
. This size (instead of #KEY_WIDTH
and #KEY_HEIGHT
) should be used to set up the decoder. The track contains #KEY_GRID_ROWS
by #KEY_GRID_COLUMNS
samples in row-major, top-row first, left-to-right order. The output image should be reconstructed by first tiling the decoding results of the tiles in the correct order, then trimming (before rotation is applied) on the bottom and right side, if the tiled area is larger than the image width and height.
Java documentation for android.media.MediaFormat.MIMETYPE_IMAGE_AVIF
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.