|
AOMedia Codec SDK
|
Describes the aom image descriptor and associated operations. More...
#include "aom/aom_integer.h"Go to the source code of this file.
Data Structures | |
| struct | aom_image |
| Image Descriptor. More... | |
| struct | aom_image_rect |
| Representation of a rectangle on a surface. More... | |
Macros | |
| #define | AOM_IMAGE_ABI_VERSION |
| Current ABI version number. | |
| #define | AOM_IMG_FMT_PLANAR 0x100 |
| #define | AOM_IMG_FMT_UV_FLIP 0x200 |
| #define | AOM_IMG_FMT_HAS_ALPHA 0x400 |
| #define | AOM_IMG_FMT_HIGHBITDEPTH 0x800 |
| #define | AOM_PLANE_PACKED 0 |
| #define | AOM_PLANE_Y 0 |
| #define | AOM_PLANE_U 1 |
| #define | AOM_PLANE_V 2 |
| #define | AOM_PLANE_ALPHA 3 |
Typedefs | |
| typedef enum aom_img_fmt | aom_img_fmt_t |
| List of supported image formats. More... | |
| typedef enum aom_color_primaries | aom_color_primaries_t |
| List of supported color primaries. More... | |
| typedef enum aom_transfer_characteristics | aom_transfer_characteristics_t |
| List of supported transfer functions. More... | |
| typedef enum aom_matrix_coefficients | aom_matrix_coefficients_t |
| List of supported matrix coefficients. | |
| typedef enum aom_color_range | aom_color_range_t |
| List of supported color range. More... | |
| typedef enum aom_chroma_sample_position | aom_chroma_sample_position_t |
| List of chroma sample positions. More... | |
| typedef struct aom_image | aom_image_t |
| Image Descriptor. More... | |
| typedef struct aom_image_rect | aom_image_rect_t |
| Representation of a rectangle on a surface. More... | |
Functions | |
| aom_image_t * | aom_img_alloc (aom_image_t *img, aom_img_fmt_t fmt, unsigned int d_w, unsigned int d_h, unsigned int align) |
| Open a descriptor, allocating storage for the underlying image. More... | |
| aom_image_t * | aom_img_wrap (aom_image_t *img, aom_img_fmt_t fmt, unsigned int d_w, unsigned int d_h, unsigned int align, unsigned char *img_data) |
| Open a descriptor, using existing storage for the underlying image. More... | |
| aom_image_t * | aom_img_alloc_with_border (aom_image_t *img, aom_img_fmt_t fmt, unsigned int d_w, unsigned int d_h, unsigned int align, unsigned int size_align, unsigned int border) |
| Open a descriptor, allocating storage for the underlying image with a border. More... | |
| int | aom_img_set_rect (aom_image_t *img, unsigned int x, unsigned int y, unsigned int w, unsigned int h, unsigned int border) |
| Set the rectangle identifying the displayed portion of the image. More... | |
| void | aom_img_flip (aom_image_t *img) |
| Flip the image vertically (top for bottom) More... | |
| void | aom_img_free (aom_image_t *img) |
| Close an image descriptor. More... | |
| int | aom_img_plane_width (const aom_image_t *img, int plane) |
| Get the width of a plane. More... | |
| int | aom_img_plane_height (const aom_image_t *img, int plane) |
| Get the height of a plane. More... | |
Describes the aom image descriptor and associated operations.
| #define AOM_IMG_FMT_PLANAR 0x100 |
Image is a planar format.
| #define AOM_IMG_FMT_UV_FLIP 0x200 |
V plane precedes U in memory.
| #define AOM_IMG_FMT_HAS_ALPHA 0x400 |
Image has an alpha channel.
| #define AOM_IMG_FMT_HIGHBITDEPTH 0x800 |
Image uses 16bit framebuffer.
| #define AOM_PLANE_PACKED 0 |
To be used for all packed formats
| #define AOM_PLANE_Y 0 |
Y (Luminance) plane
| #define AOM_PLANE_U 1 |
U (Chroma) plane
| #define AOM_PLANE_V 2 |
V (Chroma) plane
| #define AOM_PLANE_ALPHA 3 |
A (Transparency) plane
| typedef enum aom_img_fmt aom_img_fmt_t |
List of supported image formats.
alias for enum aom_img_fmt
| typedef enum aom_color_primaries aom_color_primaries_t |
List of supported color primaries.
alias for enum aom_color_primaries
List of supported transfer functions.
alias for enum aom_transfer_function
| typedef enum aom_color_range aom_color_range_t |
List of supported color range.
alias for enum aom_color_range
| typedef enum aom_chroma_sample_position aom_chroma_sample_position_t |
List of chroma sample positions.
alias for enum aom_transfer_function
| typedef struct aom_image aom_image_t |
Image Descriptor.
alias for struct aom_image
| typedef struct aom_image_rect aom_image_rect_t |
Representation of a rectangle on a surface.
alias for struct aom_image_rect
| enum aom_img_fmt |
List of supported image formats.
| enum aom_color_primaries |
List of supported color primaries.
List of supported transfer functions.
List of supported matrix coefficients.
| enum aom_color_range |
| aom_image_t* aom_img_alloc | ( | aom_image_t * | img, |
| aom_img_fmt_t | fmt, | ||
| unsigned int | d_w, | ||
| unsigned int | d_h, | ||
| unsigned int | align | ||
| ) |
Open a descriptor, allocating storage for the underlying image.
Returns a descriptor for storing an image of the given format. The storage for the descriptor is allocated on the heap.
| [in] | img | Pointer to storage for descriptor. If this parameter is NULL, the storage for the descriptor will be allocated on the heap. |
| [in] | fmt | Format for the image |
| [in] | d_w | Width of the image |
| [in] | d_h | Height of the image |
| [in] | align | Alignment, in bytes, of the image buffer and each row in the image(stride). |
| aom_image_t* aom_img_wrap | ( | aom_image_t * | img, |
| aom_img_fmt_t | fmt, | ||
| unsigned int | d_w, | ||
| unsigned int | d_h, | ||
| unsigned int | align, | ||
| unsigned char * | img_data | ||
| ) |
Open a descriptor, using existing storage for the underlying image.
Returns a descriptor for storing an image of the given format. The storage for descriptor has been allocated elsewhere, and a descriptor is desired to "wrap" that storage.
| [in] | img | Pointer to storage for descriptor. If this parameter is NULL, the storage for the descriptor will be allocated on the heap. |
| [in] | fmt | Format for the image |
| [in] | d_w | Width of the image |
| [in] | d_h | Height of the image |
| [in] | align | Alignment, in bytes, of each row in the image. |
| [in] | img_data | Storage to use for the image |
| aom_image_t* aom_img_alloc_with_border | ( | aom_image_t * | img, |
| aom_img_fmt_t | fmt, | ||
| unsigned int | d_w, | ||
| unsigned int | d_h, | ||
| unsigned int | align, | ||
| unsigned int | size_align, | ||
| unsigned int | border | ||
| ) |
Open a descriptor, allocating storage for the underlying image with a border.
Returns a descriptor for storing an image of the given format and its borders. The storage for the descriptor is allocated on the heap.
| [in] | img | Pointer to storage for descriptor. If this parameter is NULL, the storage for the descriptor will be allocated on the heap. |
| [in] | fmt | Format for the image |
| [in] | d_w | Width of the image |
| [in] | d_h | Height of the image |
| [in] | align | Alignment, in bytes, of the image buffer and each row in the image(stride). |
| [in] | size_align | Alignment, in bytes, of the image width and height. |
| [in] | border | A border that is padded on four sides of the image. |
| int aom_img_set_rect | ( | aom_image_t * | img, |
| unsigned int | x, | ||
| unsigned int | y, | ||
| unsigned int | w, | ||
| unsigned int | h, | ||
| unsigned int | border | ||
| ) |
Set the rectangle identifying the displayed portion of the image.
Updates the displayed rectangle (aka viewport) on the image surface to match the specified coordinates and size.
| [in] | img | Image descriptor |
| [in] | x | leftmost column |
| [in] | y | topmost row |
| [in] | w | width |
| [in] | h | height |
| [in] | border | A border that is padded on four sides of the image. |
| void aom_img_flip | ( | aom_image_t * | img | ) |
Flip the image vertically (top for bottom)
Adjusts the image descriptor's pointers and strides to make the image be referenced upside-down.
| [in] | img | Image descriptor |
| void aom_img_free | ( | aom_image_t * | img | ) |
Close an image descriptor.
Frees all allocated storage associated with an image descriptor.
| [in] | img | Image descriptor |
| int aom_img_plane_width | ( | const aom_image_t * | img, |
| int | plane | ||
| ) |
Get the width of a plane.
Get the width of a plane of an image
| [in] | img | Image descriptor |
| [in] | plane | Plane index |
| int aom_img_plane_height | ( | const aom_image_t * | img, |
| int | plane | ||
| ) |
Get the height of a plane.
Get the height of a plane of an image
| [in] | img | Image descriptor |
| [in] | plane | Plane index |
1.8.14