OH_Pixelmap_InitializationOptions

struct OH_Pixelmap_InitializationOptions

Overview

The OH_Pixelmap_InitializationOptions struct describes the initialization options encapsulated at the native layer. The struct is used to set the initialization parameters for a PixelMap.

To create an OH_Pixelmap_InitializationOptions object, call OH_PixelmapInitializationOptions_Create.

To release an OH_Pixelmap_InitializationOptions object, call OH_PixelmapInitializationOptions_Release.

The table below describes the content and operation mode of the OH_Pixelmap_InitializationOptions struct.

Field type. Field Name Field Description Operation Function Function Description
uint32_t width Image width. OH_PixelmapInitializationOptions_GetWidth Obtains the image width.
uint32_t width Image width. OH_PixelmapInitializationOptions_SetWidth Sets the image width.
uint32_t height Image height. OH_PixelmapInitializationOptions_GetHeight Obtains the image height.
uint32_t height Image height. OH_PixelmapInitializationOptions_SetHeight Sets the image height.
int32_t pixelFormat Pixel format. OH_PixelmapInitializationOptions_GetPixelFormat Obtains the pixel format.
int32_t pixelFormat Pixel format. OH_PixelmapInitializationOptions_SetPixelFormat Sets the pixel format.
int32_t alphaType Alpha type. OH_PixelmapInitializationOptions_GetAlphaType Obtains the alpha type.
int32_t alphaType Alpha type. OH_PixelmapInitializationOptions_SetAlphaType Sets the alpha type.

Since: 12

Related module: Image_NativeModule

Header file: pixelmap_native.h