1# Image_NativeModule
2
3
4## Overview
5
6The Image_NativeModule module provides image processing capabilities, including encoding and decoding an image and obtaining image data from the native layer.
7
8The APIs of this module do not need to be imported through the JS interface. You can directly use the NDK to develop the features.
9
10You can refer to the corresponding development guide and samples based on your development requirements.
11
12- [Using Image_NativeModule to Decode Images](../../media/image/image-source-c.md)
13- [Using Image_NativeModule to Decode Pictures](../../media/image/image-source-picture-c.md)
14- [Using Image_NativeModule to Receive Images](../../media/image/image-receiver-c.md)
15- [Using Image_NativeModule for PixelMap Operations](../../media/image/pixelmap-c.md)
16- [Using Image_NativeModule to Process Image Information](../../media/image/image-info-c.md)
17- [Using Image_NativeModule to Encode Images](../../media/image/image-packer-c.md)
18- [Using Image_NativeModule to Encode Pictures](../../media/image/image-packer-picture-c.md)
19
20**Since**: 12
21
22
23## Summary
24
25
26### Files
27
28| Name| Description|
29| -------- | -------- |
30| [image_common.h](image__common_8h.md) | Declares the common enums and structs used by the image interface. |
31| [image_native.h](image__native_8h.md) | Declares the cropping rectangle, size, and component data of an image. |
32| [image_packer_native.h](image__packer__native_8h.md) | Declares the APIs for image encoding. |
33| [image_receiver_native.h](image__receiver__native_8h.md) | Declares the APIs used to obtain image data from the native layer. |
34| [image_source_native.h](image__source__native_8h.md) | Declares the APIs for image decoding. |
35| [picture_native.h](picture__native_8h.md) | Declares the APIs for obtaining picture data and information. |
36| [pixelmap_native.h](pixelmap__native_8h.md) | Declares the APIs for accessing a PixelMap. |
37
38
39### Structs
40
41| Name| Description|
42| -------- | -------- |
43| struct  [Image_Size](_image___size.md) | Describes the image size. |
44| struct  [Image_Region](_image___region.md) | Describes the region of an image to decode. |
45| struct  [Image_String](_image___string.md) | Describes an image string. |
46| struct  [OH_Pixelmap_HdrStaticMetadata](_o_h___pixelmap___hdr_static_metadata.md) | Describes the static metadata values available for the key **HDR_STATIC_METADATA**. |
47| struct  [OH_Pixelmap_HdrDynamicMetadata](_o_h___pixelmap___hdr_dynamic_metadata.md) | Describes the dynamic metadata values available for the key **DR_DYNAMIC_METADATA**. |
48| struct  [OH_Pixelmap_HdrGainmapMetadata](_o_h___pixelmap___hdr_gainmap_metadata.md) | Describes the gain map metadata values available for the key **HDR_GAINMAP_METADATA**. For details, see ISO 21496-1. |
49| struct  [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md) | Describes the HDR metadata values used by the PixelMap and available for the key **OH_Pixelmap_HdrMetadataKey**. |
50
51
52### Types
53
54| Name| Description|
55| -------- | -------- |
56| typedef struct [Image_Size](_image___size.md) [Image_Size](#image_size) | Defines a struct for the image size. |
57| typedef struct [Image_Region](_image___region.md) [Image_Region](#image_region) | Defines a struct for the region of an image to decode. |
58| typedef struct [OH_PictureMetadata](#oh_picturemetadata) [OH_PictureMetadata](#oh_picturemetadata) | Defines a struct for the picture metadata. |
59| typedef struct [Image_String](_image___string.md) [Image_String](#image_string) | Defines a struct for an image string. |
60| typedef struct [Image_String](_image___string.md) [Image_MimeType](#image_mimetype) | Defines a struct for an image format type. |
61| typedef struct [OH_ImageNative](#oh_imagenative) [OH_ImageNative](#oh_imagenative) | Defines the alias for an image object at the native layer. |
62| typedef struct [OH_ImagePackerNative](#oh_imagepackernative) [OH_ImagePackerNative](#oh_imagepackernative) | Defines a struct for the image packer, which is used to perform operations related to an image packer. |
63| typedef struct [OH_PackingOptions](#oh_packingoptions) [OH_PackingOptions](#oh_packingoptions) | Defines a struct for image encoding parameters. |
64| typedef struct [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) | Defines a struct for image sequence encoding parameters. |
65| typedef struct [OH_ImageReceiverNative](#oh_imagereceivernative) [OH_ImageReceiverNative](#oh_imagereceivernative) | Defines the data type name of the image receiver at the native layer. |
66| typedef struct [OH_ImageReceiverOptions](#oh_imagereceiveroptions) [OH_ImageReceiverOptions](#oh_imagereceiveroptions) | Defines the data type name of the image receiver options. |
67| typedef void(\* [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback)) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver) | Defines the callbacks for the image receiver at the native layer. |
68| typedef struct [OH_ImageSourceNative](#oh_imagesourcenative) [OH_ImageSourceNative](#oh_imagesourcenative) | Defines a struct for the image source, which is used to perform operations related to an image source. |
69| typedef struct [OH_ImageSource_Info](#oh_imagesource_info) [OH_ImageSource_Info](#oh_imagesource_info) | Defines a struct for the image source information, which is created by calling [OH_ImageSourceInfo_Create](#oh_imagesourceinfo_create).|
70| typedef struct [OH_DecodingOptions](#oh_decodingoptions) [OH_DecodingOptions](#oh_decodingoptions) | Defines a struct for decoding parameters, which are used in [OH_ImageSourceNative_CreatePixelmap](#oh_imagesourcenative_createpixelmap). |
71| typedef struct [OH_PictureNative](#oh_picturenative) [OH_PictureNative](#oh_picturenative) | Defines a struct for the picture, which is used to perform operations related to the picture. |
72| typedef struct [OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) [OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) | Defines a struct for the auxiliary picture, which is used to perform operations related to the auxiliary picture. |
73| typedef struct [OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) [OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) | Defines a struct for the auxiliary picture information, which is used to perform operations related to the auxiliary picture information. |
74| typedef struct [OH_PixelmapNative](#oh_pixelmapnative) [OH_PixelmapNative](#oh_pixelmapnative) | Defines a struct for the PixelMap, which is used to perform operations related to a PixelMap.|
75| typedef struct [OH_NativeBuffer](#oh_nativebuffer) [OH_NativeBuffer](#oh_nativebuffer) | Defines a struct for the native buffer, which is used to perform operations related to the native buffer.|
76| typedef struct [OH_NativeColorSpaceManager](#oh_nativecolorspacemanager) [OH_NativeColorSpaceManager](#oh_nativecolorspacemanager) | Defines a struct for the native color space manager, which is used to perform operations related to the native color space manager. |
77| typedef struct [OH_Pixelmap_HdrStaticMetadata](_o_h___pixelmap___hdr_static_metadata.md) [OH_Pixelmap_HdrStaticMetadata](#oh_pixelmap_hdrstaticmetadata) | Defines a struct for the static metadata values available for the key **HDR_STATIC_METADATA**. |
78| typedef struct [OH_Pixelmap_HdrDynamicMetadata](_o_h___pixelmap___hdr_dynamic_metadata.md) [OH_Pixelmap_HdrDynamicMetadata](#oh_pixelmap_hdrdynamicmetadata) | Defines a struct for the dynamic metadata values available for the key **DR_DYNAMIC_METADATA**. |
79| typedef struct [OH_Pixelmap_HdrGainmapMetadata](_o_h___pixelmap___hdr_gainmap_metadata.md) [OH_Pixelmap_HdrGainmapMetadata](#oh_pixelmap_hdrgainmapmetadata) | Defines a struct for the gain map metadata values available for the key **HDR_GAINMAP_METADATA**. For details, see ISO 21496-1. |
80| typedef struct [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md) [OH_Pixelmap_HdrMetadataValue](#oh_pixelmap_hdrmetadatavalue) | Defines a struct for the HDR metadata values used by the PixelMap and available for the key **OH_Pixelmap_HdrMetadataKey**. |
81| typedef struct [OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) [OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) | Defines a struct for the initialization parameters.|
82| typedef struct [OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) [OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) | Defines a struct for the image information.|
83
84
85### Enums
86
87| Name| Description|
88| -------- | -------- |
89| [Image_ErrorCode](#image_errorcode) {<br/>IMAGE_SUCCESS = 0, <br/>IMAGE_BAD_PARAMETER = 401, <br/>IMAGE_UNSUPPORTED_MIME_TYPE = 7600101, <br/>IMAGE_UNKNOWN_MIME_TYPE = 7600102,<br/>IMAGE_TOO_LARGE = 7600103, <br/>IMAGE_DMA_NOT_EXIST = 7600173, <br/>IMAGE_DMA_OPERATION_FAILED = 7600174, <br/>IMAGE_UNSUPPORTED_OPERATION = 7600201,<br/>IMAGE_UNSUPPORTED_METADATA = 7600202, <br/>IMAGE_UNSUPPORTED_CONVERSION = 7600203, <br/>IMAGE_INVALID_REGION = 7600204, <br/>IMAGE_UNSUPPORTED_MEMORY_FORMAT = 7600205, <br/>IMAGE_ALLOC_FAILED = 7600301,<br/>IMAGE_COPY_FAILED = 7600302, <br/>IMAGE_UNKNOWN_ERROR = 7600901, <br/>IMAGE_BAD_SOURCE = 7700101, <br/>IMAGE_DECODE_FAILED = 7700301,<br/>IMAGE_ENCODE_FAILED = 7800301<br/>} | Enumerates the error codes.  |
90| [Image_MetadataType](#image_metadatatype-1) { EXIF_METADATA = 1, FRAGMENT_METADATA = 2 } | Enumerates the metadata types. |
91| [IMAGE_PACKER_DYNAMIC_RANGE](#image_packer_dynamic_range) {<br>IMAGE_PACKER_DYNAMIC_RANGE_AUTO = 0,<br>IMAGE_PACKER_DYNAMIC_RANGE_SDR = 1 } | Enumerates the desired dynamic range for encoding.|
92| [IMAGE_DYNAMIC_RANGE](#image_dynamic_range) {<br>IMAGE_DYNAMIC_RANGE_AUTO = 0,<br>IMAGE_DYNAMIC_RANGE_SDR = 1,<br>IMAGE_DYNAMIC_RANGE_HDR = 2 } | Enumerates the desired dynamic range for decoding.|
93| [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) {<br>AUXILIARY_PICTURE_TYPE_GAINMAP = 1, AUXILIARY_PICTURE_TYPE_DEPTH_MAP = 2, AUXILIARY_PICTURE_TYPE_UNREFOCUS_MAP = 3, AUXILIARY_PICTURE_TYPE_LINEAR_MAP = 4,<br>AUXILIARY_PICTURE_TYPE_FRAGMENT_MAP = 5<br>} | Enumerates the auxiliary picture types. |
94| [PIXELMAP_ALPHA_TYPE](#pixelmap_alpha_type) {<br>PIXELMAP_ALPHA_TYPE_UNKNOWN = 0,<br>PIXELMAP_ALPHA_TYPE_OPAQUE = 1,<br>PIXELMAP_ALPHA_TYPE_PREMULTIPLIED = 2 } | Enumerates the alpha types of a PixelMap.|
95| [PIXEL_FORMAT](#pixel_format) {<br>PIXEL_FORMAT_UNKNOWN = 0, PIXEL_FORMAT_RGB_565 = 2,<br>PIXEL_FORMAT_RGBA_8888 = 3, PIXEL_FORMAT_BGRA_8888 = 4,<br>PIXEL_FORMAT_RGB_888 = 5, PIXEL_FORMAT_ALPHA_8 = 6,<br>PIXEL_FORMAT_RGBA_F16 = 7, PIXEL_FORMAT_NV21 = 8,<br>PIXEL_FORMAT_NV12 = 9<br>} | Enumerates the image pixel formats.|
96| [OH_PixelmapNative_AntiAliasingLevel](#oh_pixelmapnative_antialiasinglevel) { <br>OH_PixelmapNative_AntiAliasing_NONE = 0, <br>OH_PixelmapNative_AntiAliasing_LOW = 1, <br>OH_PixelmapNative_AntiAliasing_MEDIUM = 2, <br>OH_PixelmapNative_AntiAliasing_HIGH = 3 <br>} | Enumerates the anti-aliasing levels used for scaling PixelMaps. |
97| [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey) { <br>HDR_METADATA_TYPE = 0, <br>HDR_STATIC_METADATA = 1, <br>HDR_DYNAMIC_METADATA = 2, <br>HDR_GAINMAP_METADATA = 3 } | Enumerates the keys of the HDR related metadata information used by the PixelMap. It is used in [OH_PixelmapNative_SetMetadata](#oh_pixelmapnative_setmetadata) and [OH_PixelmapNative_GetMetadata](#oh_pixelmapnative_getmetadata). |
98| [OH_Pixelmap_HdrMetadataType](#oh_pixelmap_hdrmetadatatype) { <br>HDR_METADATA_TYPE_NONE = 0, <br>HDR_METADATA_TYPE_BASE = 1, <br>HDR_METADATA_TYPE_GAINMAP = 2, <br>HDR_METADATA_TYPE_ALTERNATE = 3 } | Enumerates the HDR metadata types, which are the values of **HDR_METADATA_TYPE**. |
99
100
101### Functions
102
103| Name| Description|
104| -------- | -------- |
105| [Image_ErrorCode](#image_errorcode) [OH_PictureMetadata_Create](#oh_picturemetadata_create) ([Image_MetadataType](#image_metadatatype) metadataType, [OH_PictureMetadata](#oh_picturemetadata) \*\*metadata) | Creates the pointer to an **OH_PictureMetadata** struct. |
106| [Image_ErrorCode](#image_errorcode) [OH_PictureMetadata_GetProperty](#oh_picturemetadata_getproperty) ([OH_PictureMetadata](#oh_picturemetadata) \*metadata, [Image_String](_image___string.md) \*key, [Image_String](_image___string.md) \*value) | Obtains a property of metadata based on the key. |
107| [Image_ErrorCode](#image_errorcode) [OH_PictureMetadata_SetProperty](#oh_picturemetadata_setproperty) ([OH_PictureMetadata](#oh_picturemetadata) \*metadata, [Image_String](_image___string.md) \*key, [Image_String](_image___string.md) \*value) | Sets a property of metadata based on the key. |
108| [Image_ErrorCode](#image_errorcode) [OH_PictureMetadata_Release](#oh_picturemetadata_release) ([OH_PictureMetadata](#oh_picturemetadata) \*metadata) | Releases the pointer to an **OH_PictureMetadata** struct. |
109| [Image_ErrorCode](#image_errorcode) [OH_PictureMetadata_Clone](#oh_picturemetadata_clone) ([OH_PictureMetadata](#oh_picturemetadata) \*oldMetadata, [OH_PictureMetadata](#oh_picturemetadata) \*\*newMetadata) | Clones metadata. |
110| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetImageSize](#oh_imagenative_getimagesize) ([OH_ImageNative](#oh_imagenative) \*image, [Image_Size](_image___size.md) \*size) | Obtains the [Image_Size](_image___size.md) information of a native [OH_ImageNative](#oh_imagenative) object. |
111| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetComponentTypes](#oh_imagenative_getcomponenttypes) ([OH_ImageNative](#oh_imagenative) \*image, uint32_t \*\*types, size_t \*typeSize) | Obtains the component types of a native [OH_ImageNative](#oh_imagenative) object. |
112| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetByteBuffer](#oh_imagenative_getbytebuffer) ([OH_ImageNative](#oh_imagenative) \*image, uint32_t componentType, OH_NativeBuffer \*\*nativeBuffer) | Obtains the buffer corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object. |
113| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetBufferSize](#oh_imagenative_getbuffersize) ([OH_ImageNative](#oh_imagenative) \*image, uint32_t componentType, size_t \*size) | Obtains the size of the buffer corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object. |
114| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetRowStride](#oh_imagenative_getrowstride) ([OH_ImageNative](#oh_imagenative) \*image, uint32_t componentType, int32_t \*rowStride) | Obtains the row stride corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object. |
115| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetPixelStride](#oh_imagenative_getpixelstride) ([OH_ImageNative](#oh_imagenative) \*image, uint32_t componentType, int32_t \*pixelStride) | Obtains the pixel stride corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object. |
116| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_GetTimestamp](#oh_imagenative_gettimestamp) ([OH_ImageNative](#oh_imagenative) \*image, int64_t \*timestamp) | Obtains the timestamp of a native [OH_ImageNative](#oh_imagenative) object. |
117| [Image_ErrorCode](#image_errorcode) [OH_ImageNative_Release](#oh_imagenative_release) ([OH_ImageNative](#oh_imagenative) \*image) | Releases a native [OH_ImageNative](#oh_imagenative) object. |
118| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_Create](#oh_packingoptions_create) ([OH_PackingOptions](#oh_packingoptions) \*\*options) | Creates the pointer to an **OH_PackingOptions** struct. |
119| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_GetMimeType](#oh_packingoptions_getmimetype) ([OH_PackingOptions](#oh_packingoptions) \*options, [Image_MimeType](#image_mimetype) \*format) | Obtains the MIME type.|
120| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_SetMimeType](#oh_packingoptions_setmimetype) ([OH_PackingOptions](#oh_packingoptions) \*options, [Image_MimeType](#image_mimetype) \*format) | Sets the MIME type.|
121| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_GetQuality](#oh_packingoptions_getquality) ([OH_PackingOptions](#oh_packingoptions) \*options, uint32_t \*quality) | Obtains the encoding quality. |
122| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_SetQuality](#oh_packingoptions_setquality) ([OH_PackingOptions](#oh_packingoptions) \*options, uint32_t quality) | Sets the encoding quality. |
123| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_GetDesiredDynamicRange](#oh_packingoptions_getdesireddynamicrange) ([OH_PackingOptions](#oh_packingoptions) \*options, int32_t \*desiredDynamicRange) | Obtains the desired dynamic range during encoding. |
124| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_SetDesiredDynamicRange](#oh_packingoptions_setdesireddynamicrange) ([OH_PackingOptions](#oh_packingoptions) \*options, int32_t desiredDynamicRange) | Sets the desired dynamic range during encoding. |
125| [Image_ErrorCode](#image_errorcode) [OH_PackingOptions_Release](#oh_packingoptions_release) ([OH_PackingOptions](#oh_packingoptions) \*options) | Releases the pointer to an **OH_PackingOptions** struct. |
126| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_Create](#oh_packingoptionsforsequence_create) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*\*options) | Creates the pointer to an **OH_PackingOptionsForSequence** struct. |
127| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_SetFrameCount](#oh_packingoptionsforsequence_setframecount) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t frameCount) | Sets the number of frames for image sequence encoding. |
128| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_GetFrameCount](#oh_packingoptionsforsequence_getframecount) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t \*frameCount) | Obtains the number of frames for image sequence encoding. |
129| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_SetDelayTimeList](#oh_packingoptionsforsequence_setdelaytimelist) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, int32_t \*delayTimeList, size_t delayTimeListLength) | Sets the delay time array for image sequence encoding. |
130| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_GetDelayTimeList](#oh_packingoptionsforsequence_getdelaytimelist) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, int32_t \*delayTimeList, size_t delayTimeListLength) | Obtains the delay time array for image sequence encoding. |
131| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_SetDisposalTypes](#oh_packingoptionsforsequence_setdisposaltypes) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t \*disposalTypes, size_t disposalTypesLength) | Sets the disposal type array for image sequence encoding. |
132| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_GetDisposalTypes](#oh_packingoptionsforsequence_getdisposaltypes) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t \*disposalTypes, size_t disposalTypesLength) | Obtains the disposal type array for image sequence encoding. |
133| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_SetLoopCount](#oh_packingoptionsforsequence_setloopcount) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t loopCount) | Sets the number of loops for image sequence encoding. |
134| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_GetLoopCount](#oh_packingoptionsforsequence_getloopcount) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, uint32_t \*loopCount) | Obtains the number of loops for image sequence encoding. |
135| [Image_ErrorCode](#image_errorcode) [OH_PackingOptionsForSequence_Release](#oh_packingoptionsforsequence_release) ([OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options) | Releases the pointer to an **OH_PackingOptionsForSequence** object. |
136| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_Create](#oh_imagepackernative_create) ([OH_ImagePackerNative](#oh_imagepackernative) \*\*imagePacker) | Creates the pointer to an **OH_ImagePackerNative** object. |
137| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToDataFromImageSource](#oh_imagepackernative_packtodatafromimagesource) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_ImageSourceNative](#oh_imagesourcenative) \*imageSource, uint8_t \*outData, size_t \*size) | Encodes an image source into data in a given format. |
138| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToDataFromPixelmap](#oh_imagepackernative_packtodatafrompixelmap) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, uint8_t \*outData, size_t \*size) | Encodes a PixelMap into data in a given format. |
139| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToDataFromPicture](#oh_imagepackernative_packtodatafrompicture) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_PictureNative](#oh_picturenative) \*picture, uint8_t \*outData, size_t \*size) | Encodes a picture into data in a given format. |
140| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToDataFromPixelmapSequence](#oh_imagepackernative_packtodatafrompixelmapsequence) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, [OH_ImagePackerNative](#oh_imagepackernative) \*\*pixelmapSequence, size_t sequenceLength, uint8_t \*outData, size_t \*outDataSize) | Encodes a PixelMap sequence into data. |
141| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToFileFromImageSource](#oh_imagepackernative_packtofilefromimagesource) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_ImageSourceNative](#oh_imagesourcenative) \*imageSource, int32_t fd) | Encodes an image source into a file. |
142| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToFileFromPixelmap](#oh_imagepackernative_packtofilefrompixelmap) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, int32_t fd) | Encodes a PixelMap into a file. |
143| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToFileFromPicture](#oh_imagepackernative_packtofilefrompicture) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptions](#oh_packingoptions) \*options, [OH_PictureNative](#oh_picturenative) \*picture, int32_t fd) | Encodes a picture into a file. |
144| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_PackToFileFromPixelmapSequence](#oh_imagepackernative_packtofilefrompixelmapsequence) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker, [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) \*options, [OH_ImagePackerNative](#oh_imagepackernative) \*\*pixelmapSequence, size_t sequenceLength, int32_t fd) | Encodes a PixelMap sequence into a file. |
145| [Image_ErrorCode](#image_errorcode) [OH_ImagePackerNative_Release](#oh_imagepackernative_release) ([OH_ImagePackerNative](#oh_imagepackernative) \*imagePacker) | Releases the pointer to an **OH_ImagePackerNative** object. |
146| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_Create](#oh_imagereceiveroptions_create) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*\*options) | Creates an **OH_ImageReceiverOptions** object at the application layer. |
147| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_GetSize](#oh_imagereceiveroptions_getsize) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options, [Image_Size](_image___size.md) \*size) | Obtains the [Image_Size](_image___size.md) information of an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
148| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_SetSize](#oh_imagereceiveroptions_setsize) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options, [Image_Size](_image___size.md) size) | Sets the [Image_Size](_image___size.md) information for an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
149| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_GetCapacity](#oh_imagereceiveroptions_getcapacity) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options, int32_t \*capacity) | Obtains the capacity of an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
150| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_SetCapacity](#oh_imagereceiveroptions_setcapacity) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options, int32_t capacity) | Sets the capacity for an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
151| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverOptions_Release](#oh_imagereceiveroptions_release) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options) | Releases an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
152| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_Create](#oh_imagereceivernative_create) ([OH_ImageReceiverOptions](#oh_imagereceiveroptions) \*options, [OH_ImageReceiverNative](#oh_imagereceivernative) \*\*receiver) | Creates an **OH_ImageReceiverNative** object at the application layer. |
153| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_GetReceivingSurfaceId](#oh_imagereceivernative_getreceivingsurfaceid) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, uint64_t \*surfaceId) | Obtains the receiver ID through an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
154| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_ReadLatestImage](#oh_imagereceivernative_readlatestimage) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, [OH_ImageNative](#oh_imagenative) \*\*image) | Obtains the latest image through an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
155| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_ReadNextImage](#oh_imagereceivernative_readnextimage) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, [OH_ImageNative](#oh_imagenative) \*\*image) | Obtains the next image through an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
156| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_On](#oh_imagereceivernative_on) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback) callback) | Registers the callback defined in [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback). |
157| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_Off](#oh_imagereceivernative_off) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver) | Unregisters the callback defined in [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback). |
158| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_GetSize](#oh_imagereceivernative_getsize) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, [Image_Size](_image___size.md) \*size) | Obtains the size of an image receiver, which is an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
159| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_GetCapacity](#oh_imagereceivernative_getcapacity) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver, int32_t \*capacity) | Obtains the capacity of an image receiver, which is an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
160| [Image_ErrorCode](#image_errorcode) [OH_ImageReceiverNative_Release](#oh_imagereceivernative_release) ([OH_ImageReceiverNative](#oh_imagereceivernative) \*receiver) | Releases a native [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
161| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceInfo_Create](#oh_imagesourceinfo_create) ([OH_ImageSource_Info](#oh_imagesource_info) \*\*info) | Creates the pointer to an **OH_ImageSource_Info** struct. |
162| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceInfo_GetWidth](#oh_imagesourceinfo_getwidth) ([OH_ImageSource_Info](#oh_imagesource_info) \*info, uint32_t \*width) | Obtains the image width. |
163| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceInfo_GetHeight](#oh_imagesourceinfo_getheight) ([OH_ImageSource_Info](#oh_imagesource_info) \*info, uint32_t \*height) | Obtains the image height. |
164| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceInfo_GetDynamicRange](#oh_imagesourceinfo_getdynamicrange) ([OH_ImageSource_Info](#oh_imagesource_info) \*info, bool \*isHdr) | Obtains the dynamic range of an image. |
165| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceInfo_Release](#oh_imagesourceinfo_release) ([OH_ImageSource_Info](#oh_imagesource_info) \*info) | Releases the pointer to an **OH_ImageSource_Info** struct. |
166| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_Create](#oh_decodingoptions_create) ([OH_DecodingOptions](#oh_decodingoptions) \*\*options) | Creates the pointer to an **OH_DecodingOptions** struct. |
167| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetPixelFormat](#oh_decodingoptions_getpixelformat) ([OH_DecodingOptions](#oh_decodingoptions) \*options, int32_t \*pixelFormat) | Obtains the pixel format. |
168| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetPixelFormat](#oh_decodingoptions_setpixelformat) ([OH_DecodingOptions](#oh_decodingoptions) \*options, int32_t pixelFormat) | Sets the pixel format. |
169| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetIndex](#oh_decodingoptions_getindex) ([OH_DecodingOptions](#oh_decodingoptions) \*options, uint32_t \*index) | Obtains the index of an image. |
170| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetIndex](#oh_decodingoptions_setindex) ([OH_DecodingOptions](#oh_decodingoptions) \*options, uint32_t index) | Sets the index for an image. |
171| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetRotate](#oh_decodingoptions_getrotate) ([OH_DecodingOptions](#oh_decodingoptions) \*options, float \*rotate) | Obtains the rotation degree. |
172| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetRotate](#oh_decodingoptions_setrotate) ([OH_DecodingOptions](#oh_decodingoptions) \*options, float rotate) | Sets the rotation angle. |
173| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetDesiredSize](#oh_decodingoptions_getdesiredsize) ([OH_DecodingOptions](#oh_decodingoptions) \*options, [Image_Size](_image___size.md) \*desiredSize) | Obtains the desired output size. |
174| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetDesiredSize](#oh_decodingoptions_setdesiredsize) ([OH_DecodingOptions](#oh_decodingoptions) \*options, [Image_Size](_image___size.md) \*desiredSize) | Sets the desired output size. |
175| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetDesiredRegion](#oh_decodingoptions_getdesiredregion) ([OH_DecodingOptions](#oh_decodingoptions) \*options, [Image_Region](_image___region.md) \*desiredRegion) | Obtains the region to decode. |
176| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetDesiredRegion](#oh_decodingoptions_setdesiredregion) ([OH_DecodingOptions](#oh_decodingoptions) \*options, [Image_Region](_image___region.md) \*desiredRegion) | Sets the region to decode. |
177| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_GetDesiredDynamicRange](#oh_decodingoptions_getdesireddynamicrange) ([OH_DecodingOptions](#oh_decodingoptions) \*options, int32_t \*desiredDynamicRange) | Obtains the desired dynamic range configured during decoding. |
178| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_SetDesiredDynamicRange](#oh_decodingoptions_setdesireddynamicrange) ([OH_DecodingOptions](#oh_decodingoptions) \*options, int32_t desiredDynamicRange) | Sets the desired dynamic range during decoding. |
179| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptions_Release](#oh_decodingoptions_release) ([OH_DecodingOptions](#oh_decodingoptions) \*options) | Releases the pointer to an **OH_DecodingOptions** struct. |
180| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreateFromUri](#oh_imagesourcenative_createfromuri) (char \*uri, size_t uriSize, [OH_ImageSourceNative](#oh_imagesourcenative) \*\*res) | Creates the pointer to an **OH_ImageSourceNative** object based on a URI. |
181| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreateFromFd](#oh_imagesourcenative_createfromfd) (int32_t fd, [OH_ImageSourceNative](#oh_imagesourcenative) \*\*res) | Creates the pointer to an **OH_ImageSourceNative** object based on a file descriptor. |
182| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreateFromData](#oh_imagesourcenative_createfromdata) (uint8_t \*data, size_t dataSize, [OH_ImageSourceNative](#oh_imagesourcenative) \*\*res) | Creates the pointer to an **OH_ImageSourceNative** object based on buffer data. |
183| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreateFromRawFile](#oh_imagesourcenative_createfromrawfile) (RawFileDescriptor \*rawFile, [OH_ImageSourceNative](#oh_imagesourcenative) \*\*res) | Creates the pointer to an **OH_ImageSourceNative** object by using the raw file descriptor of an image resource file. |
184| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreatePixelmap](#oh_imagesourcenative_createpixelmap) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, [OH_DecodingOptions](#oh_decodingoptions) \*options, [OH_PixelmapNative](#oh_pixelmapnative) \*\*pixelmap) | Creates the pointer to an **OH_PixelmapNative** object based on image decoding parameters. |
185| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreatePixelmapList](#oh_imagesourcenative_createpixelmaplist) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, [OH_DecodingOptions](#oh_decodingoptions) \*options, OH_PixelmapNative \*resVecPixMap[], size_t size) | Creates an array of **OH_PixelmapNative** objects based on image decoding parameters. |
186| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_CreatePicture](#oh_imagesourcenative_createpicture) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, OH_DecodingOptionsForPicture \*options, [OH_PictureNative](#oh_picturenative) \*\*picture) | Creates the pointer to an **OH_PictureNative** object based on image decoding parameters. |
187| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_GetDelayTimeList](#oh_imagesourcenative_getdelaytimelist) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, int32_t \*delayTimeList, size_t size) | Obtains the image delay time list. |
188| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_GetImageInfo](#oh_imagesourcenative_getimageinfo) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, int32_t index, [OH_ImageSource_Info](#oh_imagesource_info) \*info) | Obtains the information about an image with a given index. |
189| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_GetImageProperty](#oh_imagesourcenative_getimageproperty) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, [Image_String](_image___string.md) \*key, [Image_String](_image___string.md) \*value) | Obtains the value of an image property. |
190| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_ModifyImageProperty](#oh_imagesourcenative_modifyimageproperty) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, [Image_String](_image___string.md) \*key, [Image_String](_image___string.md) \*value) | Modifies the value of an image property. |
191| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_GetFrameCount](#oh_imagesourcenative_getframecount) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source, uint32_t \*frameCount) | Obtains the number of image frames. |
192| [Image_ErrorCode](#image_errorcode) [OH_ImageSourceNative_Release](#oh_imagesourcenative_release) ([OH_ImageSourceNative](#oh_imagesourcenative) \*source) | Releases the pointer to an **OH_ImageSourceNative** object. |
193| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptionsForPicture_Create](#oh_decodingoptionsforpicture_create) (OH_DecodingOptionsForPicture \*\*options) | Creates the pointer to an **OH_DecodingOptionsForPicture** struct. |
194| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptionsForPicture_GetDesiredAuxiliaryPictures](#oh_decodingoptionsforpicture_getdesiredauxiliarypictures) (OH_DecodingOptionsForPicture \*options, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) \*\*desiredAuxiliaryPictures, size_t \*length) | Obtains desired auxiliary pictures in the decoding parameters (auxiliary pictures contained in **picture** expected to be decoded.) |
195| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptionsForPicture_SetDesiredAuxiliaryPictures](#oh_decodingoptionsforpicture_setdesiredauxiliarypictures) (OH_DecodingOptionsForPicture \*options, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) \*desiredAuxiliaryPictures, size_t length) | Sets desired auxiliary pictures in the decoding parameters. |
196| [Image_ErrorCode](#image_errorcode) [OH_DecodingOptionsForPicture_Release](#oh_decodingoptionsforpicture_release) (OH_DecodingOptionsForPicture \*options) | Releases the pointer to an **OH_DecodingOptionsForPicture** struct. |
197| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_CreatePicture](#oh_picturenative_createpicture) (OH_PixelmapNative \*mainPixelmap, [OH_PictureNative](#oh_picturenative) \*\*picture) | Creates the pointer to an **OH_PictureNative** object. |
198| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_GetMainPixelmap](#oh_picturenative_getmainpixelmap) ([OH_PictureNative](#oh_picturenative) \*picture, OH_PixelmapNative \*\*mainPixelmap) | Obtains the pointer to an **OH_PixelmapNative** object of a main picture. |
199| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_GetHdrComposedPixelmap](#oh_picturenative_gethdrcomposedpixelmap) ([OH_PictureNative](#oh_picturenative) \*picture, OH_PixelmapNative \*\*hdrPixelmap) | Obtains the pointer to an **OH_PixelmapNative** object of an HDR picture. |
200| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_GetGainmapPixelmap](#oh_picturenative_getgainmappixelmap) ([OH_PictureNative](#oh_picturenative) \*picture, OH_PixelmapNative \*\*gainmapPixelmap) | Obtains the pointer to an **OH_PixelmapNative** object of a gain map. |
201| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_SetAuxiliaryPicture](#oh_picturenative_setauxiliarypicture) ([OH_PictureNative](#oh_picturenative) \*picture, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) type, [OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture) | Sets an auxiliary picture. |
202| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_GetAuxiliaryPicture](#oh_picturenative_getauxiliarypicture) ([OH_PictureNative](#oh_picturenative) \*picture, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) type, [OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*\*auxiliaryPicture) | Obtains an auxiliary picture by type. |
203| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_GetMetadata](#oh_picturenative_getmetadata) ([OH_PictureNative](#oh_picturenative) \*picture, [Image_MetadataType](#image_metadatatype) metadataType, [OH_PictureMetadata](#oh_picturemetadata) \*\*metadata) | Obtains the metadata of a main picture. |
204| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_SetMetadata](#oh_picturenative_setmetadata) ([OH_PictureNative](#oh_picturenative) \*picture, [Image_MetadataType](#image_metadatatype) metadataType, [OH_PictureMetadata](#oh_picturemetadata) \*metadata) | Sets the metadata for a main picture. |
205| [Image_ErrorCode](#image_errorcode) [OH_PictureNative_Release](#oh_picturenative_release) ([OH_PictureNative](#oh_picturenative) \*picture) | Releases the pointer to an **OH_PictureNative** object. |
206| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_Create](#oh_auxiliarypicturenative_create) (uint8_t \*data, size_t dataLength, [Image_Size](_image___size.md) \*size, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) type, [OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*\*auxiliaryPicture) | Creates the pointer to an **OH_AuxiliaryPictureNative** object. |
207| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_WritePixels](#oh_auxiliarypicturenative_writepixels) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, uint8_t \*source, size_t bufferSize) | Reads the pixels in the buffer and writes the result to an auxiliary picture. |
208| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_ReadPixels](#oh_auxiliarypicturenative_readpixels) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, uint8_t \*destination, size_t \*bufferSize) | Reads the pixels of an auxiliary picture and writes the result to the buffer. |
209| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_GetType](#oh_auxiliarypicturenative_gettype) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) \*type) | Obtains the type of an auxiliary picture. |
210| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_GetInfo](#oh_auxiliarypicturenative_getinfo) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, [OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*\*info) | Obtains the auxiliary picture information. |
211| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_SetInfo](#oh_auxiliarypicturenative_setinfo) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, [OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info) | Sets the auxiliary picture information. |
212| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_GetMetadata](#oh_auxiliarypicturenative_getmetadata) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, [Image_MetadataType](#image_metadatatype) metadataType, [OH_PictureMetadata](#oh_picturemetadata) \*\*metadata) | Obtains the metadata of an auxiliary picture. |
213| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_SetMetadata](#oh_auxiliarypicturenative_setmetadata) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*auxiliaryPicture, [Image_MetadataType](#image_metadatatype) metadataType, [OH_PictureMetadata](#oh_picturemetadata) \*metadata) | Sets the metadata for an auxiliary picture. |
214| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureNative_Release](#oh_auxiliarypicturenative_release) ([OH_AuxiliaryPictureNative](#oh_auxiliarypicturenative) \*picture) | Releases the pointer to an **OH_AuxiliaryPictureNative** object. |
215| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_Create](#oh_auxiliarypictureinfo_create) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*\*info) | Creates an **OH_AuxiliaryPictureInfo** object. |
216| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_GetType](#oh_auxiliarypictureinfo_gettype) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) \*type) | Obtains the auxiliary picture type from the auxiliary picture information. |
217| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_SetType](#oh_auxiliarypictureinfo_settype) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, [Image_AuxiliaryPictureType](#image_auxiliarypicturetype) type) | Sets the auxiliary picture type in the auxiliary picture information. |
218| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_GetSize](#oh_auxiliarypictureinfo_getsize) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, [Image_Size](_image___size.md) \*size) | Obtains the size of an auxiliary picture. |
219| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_SetSize](#oh_auxiliarypictureinfo_setsize) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, [Image_Size](_image___size.md) \*size) | Sets the size of an auxiliary picture. |
220| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_GetRowStride](#oh_auxiliarypictureinfo_getrowstride) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, uint32_t \*rowStride) | Obtains the row stride of an auxiliary picture. |
221| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_SetRowStride](#oh_auxiliarypictureinfo_setrowstride) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, uint32_t rowStride) | Sets the row stride of an auxiliary picture. |
222| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_GetPixelFormat](#oh_auxiliarypictureinfo_getpixelformat) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, PIXEL_FORMAT \*pixelFormat) | Obtains the pixel format of an auxiliary picture. |
223| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_SetPixelFormat](#oh_auxiliarypictureinfo_setpixelformat) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info, PIXEL_FORMAT pixelFormat) | Sets the pixel format of an auxiliary picture. |
224| [Image_ErrorCode](#image_errorcode) [OH_AuxiliaryPictureInfo_Release](#oh_auxiliarypictureinfo_release) ([OH_AuxiliaryPictureInfo](#oh_auxiliarypictureinfo) \*info) | Releases the pointer to an **OH_AuxiliaryPictureInfo** object. |
225| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_Create](#oh_pixelmapinitializationoptions_create) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*\*options) | Creates the pointer to an **OH_Pixelmap_InitializationOptions** struct.|
226| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetWidth](#oh_pixelmapinitializationoptions_getwidth) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, uint32_t \*width) | Obtains the image width. |
227| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetWidth](#oh_pixelmapinitializationoptions_setwidth) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, uint32_t width) | Sets the image width. |
228| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetHeight](#oh_pixelmapinitializationoptions_getheight) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, uint32_t \*height) | Obtains the image height. |
229| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetHeight](#oh_pixelmapinitializationoptions_setheight) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, uint32_t height) | Sets the image height. |
230| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetPixelFormat](#oh_pixelmapinitializationoptions_getpixelformat) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t \*pixelFormat) | Obtains the pixel format. |
231| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetPixelFormat](#oh_pixelmapinitializationoptions_setpixelformat) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t pixelFormat) | Sets the pixel format. |
232| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetSrcPixelFormat](#oh_pixelmapinitializationoptions_getsrcpixelformat) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t \*srcpixelFormat) | Obtains the source pixel format. |
233| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetSrcPixelFormat](#oh_pixelmapinitializationoptions_setsrcpixelformat) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t srcpixelFormat) | Sets the source pixel format. |
234| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetRowStride](#oh_pixelmapinitializationoptions_getrowstride) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t \*rowStride) | Obtains the row stride. |
235| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetRowStride](#oh_pixelmapinitializationoptions_setrowstride) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t rowStride) | Sets the row stride. |
236| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_GetAlphaType](#oh_pixelmapinitializationoptions_getalphatype) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t \*alphaType) | Obtains the alpha type. |
237| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_SetAlphaType](#oh_pixelmapinitializationoptions_setalphatype) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, int32_t alphaType) | Sets the alpha type. |
238| [Image_ErrorCode](#image_errorcode) [OH_PixelmapInitializationOptions_Release](#oh_pixelmapinitializationoptions_release) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options) | Releases the pointer to an **OH_Pixelmap_InitializationOptions** struct. |
239| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_Create](#oh_pixelmapimageinfo_create) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*\*info) | Creates the pointer to an **OH_Pixelmap_ImageInfo** struct. |
240| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetWidth](#oh_pixelmapimageinfo_getwidth) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, uint32_t \*width) | Obtains the image width. |
241| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetHeight](#oh_pixelmapimageinfo_getheight) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, uint32_t \*height) | Obtains the image height. |
242| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetRowStride](#oh_pixelmapimageinfo_getrowstride) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, uint32_t \*rowStride) | Obtains the row stride. |
243| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetPixelFormat](#oh_pixelmapimageinfo_getpixelformat) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, int32_t \*pixelFormat) | Obtains the pixel format. |
244| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetAlphaType](#oh_pixelmapimageinfo_getalphatype) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, int32_t \*alphaType) | Obtains the alpha type. |
245| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_GetDynamicRange](#oh_pixelmapimageinfo_getdynamicrange) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info, bool \*isHdr) | Obtains the dynamic range of a PixelMap. |
246| [Image_ErrorCode](#image_errorcode) [OH_PixelmapImageInfo_Release](#oh_pixelmapimageinfo_release) ([OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*info) | Releases the pointer to an **OH_Pixelmap_ImageInfo** struct. |
247| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_CreatePixelmap](#oh_pixelmapnative_createpixelmap) (uint8_t \*data, size_t dataLength, [OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, [OH_PixelmapNative](#oh_pixelmapnative) \*\*pixelmap) | Creates a PixelMap based on properties. By default, the BGRA_8888 format is used for data processing. |
248| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ConvertPixelmapNativeToNapi](#oh_pixelmapnative_convertpixelmapnativetonapi) (napi_env env, [OH_PixelmapNative](#oh_pixelmapnative) \*pixelmapNative, napi_value \*pixelmapNapi) | Converts a **nativePixelMap** object to a **PixelMapnapi** object. |
249| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ConvertPixelmapNativeFromNapi](#oh_pixelmapnative_convertpixelmapnativefromnapi) (napi_env env, napi_value pixelmapNapi, [OH_PixelmapNative](#oh_pixelmapnative) \*\*pixelmapNative) | Converts a **PixelMapnapi** object to a **nativePixelMap** object. |
250| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ReadPixels](#oh_pixelmapnative_readpixels) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, uint8_t \*destination, size_t \*bufferSize) | Reads the pixels of a PixelMap and writes the result to an ArrayBuffer. |
251| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_WritePixels](#oh_pixelmapnative_writepixels) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, uint8_t \*source, size_t bufferSize) | Reads the pixels in the buffer and writes the result to a PixelMap. |
252| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_GetArgbPixels](#oh_pixelmapnative_getargbpixels) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, uint8_t \*destination, size_t \*bufferSize) | Reads data in ARGB format from a PixelMap. |
253| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ToSdr](#oh_pixelmapnative_tosdr) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap) | Converts a PixelMap from the HDR format to the SDR format. |
254| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_GetImageInfo](#oh_pixelmapnative_getimageinfo) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [OH_Pixelmap_ImageInfo](#oh_pixelmap_imageinfo) \*imageInfo) | Obtains the image information of a PixelMap. |
255| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Opacity](#oh_pixelmapnative_opacity) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, float rate) | Sets the opacity rate to enable the PixelMap to achieve the corresponding opacity effect. |
256| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Scale](#oh_pixelmapnative_scale) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, float scaleX, float scaleY) | Scales a PixelMap based on a given width and height. |
257| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ScaleWithAntiAliasing](#oh_pixelmapnative_scalewithantialiasing) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, float scaleX, float scaleY, [OH_PixelmapNative_AntiAliasingLevel](#oh_pixelmapnative_antialiasinglevel) level) | Scales a PixelMap based on the specified anti-aliasing level, width, and height. |
258| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Translate](#oh_pixelmapnative_translate) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, float x, float y) | Translates a PixelMap based on given coordinates. |
259| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Rotate](#oh_pixelmapnative_rotate) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, float angle) | Rotates a PixelMap based on a given angle. |
260| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Flip](#oh_pixelmapnative_flip) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, bool shouldFilpHorizontally, bool shouldFilpVertically) | Flips a PixelMap based on a given angle. |
261| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Crop](#oh_pixelmapnative_crop) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [Image_Region](_image___region.md) \*region) | Crops a PixelMap based on a given size. |
262| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_Release](#oh_pixelmapnative_release) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap) | Releases the pointer to an **OH_PixelmapNative** object. |
263| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_ConvertAlphaFormat](#oh_pixelmapnative_convertalphaformat) ([OH_PixelmapNative](#oh_pixelmapnative) \*srcpixelmap, [OH_PixelmapNative](#oh_pixelmapnative) \*dstpixelmap, const bool isPremul) | Converts pixel data of a PixelMap from premultiplied alpha to non-premultiplied alpha, or vice versa. |
264| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_CreateEmptyPixelmap](#oh_pixelmapnative_createemptypixelmap) ([OH_Pixelmap_InitializationOptions](#oh_pixelmap_initializationoptions) \*options, [OH_PixelmapNative](#oh_pixelmapnative) \*\*pixelmap) | Creates an empty PixelMap using **OH_Pixelmap_InitializationOptions**. The memory data is 0. |
265| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_GetNativeBuffer](#oh_pixelmapnative_getnativebuffer) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, OH_NativeBuffer \*\*nativeBuffer) | Obtains the **NativeBuffer** object from a PixelMap in the DMA memory. |
266| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_GetMetadata](#oh_pixelmapnative_getmetadata) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey) key, [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md) \*\*value) | Obtains the metadata. |
267| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_SetMetadata](#oh_pixelmapnative_setmetadata) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey) key, [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md) \*value) | Sets the metadata. |
268| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_SetColorSpaceNative](#oh_pixelmapnative_setcolorspacenative) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [OH_NativeColorSpaceManager](#oh_nativecolorspacemanager) \*colorSpaceNative) | Sets a **NativeColorSpaceManager** object. |
269| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_GetColorSpaceNative](#oh_pixelmapnative_getcolorspacenative) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, [OH_NativeColorSpaceManager](#oh_nativecolorspacemanager) \*\*colorSpaceNative) | Obtains a **NativeColorSpaceManager** object. |
270| [Image_ErrorCode](#image_errorcode) [OH_PixelmapNative_SetMemoryName](#oh_pixelmapnative_setmemoryname) ([OH_PixelmapNative](#oh_pixelmapnative) \*pixelmap, char \*name, size_t \*size) | Sets the memory name of a PixelMap. |
271
272
273### Variables
274
275| Name| Description|
276| -------- | -------- |
277| static const char \*[MIME_TYPE_BMP](#mime_type_bmp) = "image/bmp" | BMP image format.|
278| static const char \*[MIME_TYPE_JPEG](#mime_type_jpeg) = "image/jpeg" | JPEG image format.|
279| static const char \*[MIME_TYPE_HEIC](#mime_type_heic) = "image/heic" | HEIF image format.|
280| static const char \*[MIME_TYPE_PNG](#mime_type_png) = "image/png" | PNG image format.|
281| static const char \*[MIME_TYPE_WEBP](#mime_type_webp) = "image/webp" | WebP image format.|
282| static const char \*[MIME_TYPE_GIF](#mime_type_gif) = "image/gif" | GIF image format.|
283| static const char \*[MIME_TYPE_ICON](#mime_type_icon) = "image/x-icon" | ICO image format.|
284| static const char \*[OHOS_IMAGE_PROPERTY_BITS_PER_SAMPLE](#ohos_image_property_bits_per_sample) = "BitsPerSample" | Number of bits per sample.|
285| static const char \*[OHOS_IMAGE_PROPERTY_ORIENTATION](#ohos_image_property_orientation) = "Orientation" | Image orientation.|
286| static const char \*[OHOS_IMAGE_PROPERTY_IMAGE_LENGTH](#ohos_image_property_image_length) = "ImageLength" | Image length.|
287| static const char \*[OHOS_IMAGE_PROPERTY_IMAGE_WIDTH](#ohos_image_property_image_width) = "ImageWidth" | Image width.|
288| static const char \*[OHOS_IMAGE_PROPERTY_GPS_LATITUDE](#ohos_image_property_gps_latitude) = "GPSLatitude" | Image latitude.|
289| static const char \*[OHOS_IMAGE_PROPERTY_GPS_LONGITUDE](#ohos_image_property_gps_longitude) = "GPSLongitude" | Image longitude.|
290| static const char \*[OHOS_IMAGE_PROPERTY_GPS_LATITUDE_REF](#ohos_image_property_gps_latitude_ref) = "GPSLatitudeRef" | Whether the latitude is north or south latitude.|
291| static const char \*[OHOS_IMAGE_PROPERTY_GPS_LONGITUDE_REF](#ohos_image_property_gps_longitude_ref) = "GPSLongitudeRef" | Whether the longitude is east or west longitude.|
292| static const char \*[OHOS_IMAGE_PROPERTY_DATE_TIME_ORIGINAL](#ohos_image_property_date_time_original) = "DateTimeOriginal" | Shooting time, for example, 2022:09:06 15:48:00.|
293| static const char \*[OHOS_IMAGE_PROPERTY_EXPOSURE_TIME](#ohos_image_property_exposure_time) = "ExposureTime" | Exposure time, for example, 1/33 seconds.|
294| static const char \*[OHOS_IMAGE_PROPERTY_SCENE_TYPE](#ohos_image_property_scene_type) = "SceneType" | Type of the scene, for example, portrait, scenery, motion, and night.|
295| static const char \*[OHOS_IMAGE_PROPERTY_ISO_SPEED_RATINGS](#ohos_image_property_iso_speed_ratings) = "ISOSpeedRatings" | ISO sensitivity or ISO speed, for example, 400.|
296| static const char \*[OHOS_IMAGE_PROPERTY_F_NUMBER](#ohos_image_property_f_number) = "FNumber" | F number, for example, f/1.8.|
297| static const char \*[OHOS_IMAGE_PROPERTY_COMPRESSED_BITS_PER_PIXEL](#ohos_image_property_compressed_bits_per_pixel) = "CompressedBitsPerPixel" | Number of bits per pixel. It is specific to compressed data.|
298| static const char \*[OHOS_IMAGE_PROPERTY_COMPRESSION](#ohos_image_property_compression) = "Compression" | Compression scheme used on the image data.|
299| static const char \*[OHOS_IMAGE_PROPERTY_PHOTOMETRIC_INTERPRETATION](#ohos_image_property_photometric_interpretation) = "PhotometricInterpretation" | Color space of the image data, for example, RGB or YCbCr.|
300| static const char \*[OHOS_IMAGE_PROPERTY_STRIP_OFFSETS](#ohos_image_property_strip_offsets) = "StripOffsets" | Byte offset of each strip.|
301| static const char \*[OHOS_IMAGE_PROPERTY_SAMPLES_PER_PIXEL](#ohos_image_property_samples_per_pixel) = "SamplesPerPixel" | Number of components per pixel. The value is **3** for RGB and YCbCr images. The **JPEG** key is used in JPEG compressed data.|
302| static const char \*[OHOS_IMAGE_PROPERTY_ROWS_PER_STRIP](#ohos_image_property_rows_per_strip) = "RowsPerStrip" | Number of rows per strip.|
303| static const char \*[OHOS_IMAGE_PROPERTY_STRIP_BYTE_COUNTS](#ohos_image_property_strip_byte_counts) = "StripByteCounts" | Number of bytes in each strip after compression.|
304| static const char \*[OHOS_IMAGE_PROPERTY_X_RESOLUTION](#ohos_image_property_x_resolution) = "XResolution" | Number of pixels per ResolutionUnit in the image width (X) direction.|
305| static const char \*[OHOS_IMAGE_PROPERTY_Y_RESOLUTION](#ohos_image_property_y_resolution) = "YResolution" | Number of pixels per ResolutionUnit in the image height (Y) direction.|
306| static const char \*[OHOS_IMAGE_PROPERTY_PLANAR_CONFIGURATION](#ohos_image_property_planar_configuration) = "PlanarConfiguration" | Storage format of components of each pixel, which can be chunky or planar.|
307| static const char \*[OHOS_IMAGE_PROPERTY_RESOLUTION_UNIT](#ohos_image_property_resolution_unit) = "ResolutionUnit" | Unit of measurement for XResolution and YResolution.|
308| static const char \*[OHOS_IMAGE_PROPERTY_TRANSFER_FUNCTION](#ohos_image_property_transfer_function) = "TransferFunction" | Transfer function for the image, which is usually used for color correction.|
309| static const char \*[OHOS_IMAGE_PROPERTY_SOFTWARE](#ohos_image_property_software) = "Software" | Name and version number of the software used to create the image.|
310| static const char \*[OHOS_IMAGE_PROPERTY_ARTIST](#ohos_image_property_artist) = "Artist" | Person who created the image.|
311| static const char \*[OHOS_IMAGE_PROPERTY_WHITE_POINT](#ohos_image_property_white_point) = "WhitePoint" | Chromaticity of the white point of the image.|
312| static const char \*[OHOS_IMAGE_PROPERTY_PRIMARY_CHROMATICITIES](#ohos_image_property_primary_chromaticities) = "PrimaryChromaticities" | Chromaticities of the primaries of the image.|
313| static const char \*[OHOS_IMAGE_PROPERTY_YCBCR_COEFFICIENTS](#ohos_image_property_ycbcr_coefficients) = "YCbCrCoefficients" | Transformation from RGB to YCbCr image data.|
314| static const char \*[OHOS_IMAGE_PROPERTY_YCBCR_SUB_SAMPLING](#ohos_image_property_ycbcr_sub_sampling) = "YCbCrSubSampling" | Subsampling factors used for the chrominance components of a YCbCr image.|
315| static const char \*[OHOS_IMAGE_PROPERTY_YCBCR_POSITIONING](#ohos_image_property_ycbcr_positioning) = "YCbCrPositioning" | Positioning of subsampled chrominance components relative to luminance samples.|
316| static const char \*[OHOS_IMAGE_PROPERTY_REFERENCE_BLACK_WHITE](#ohos_image_property_reference_black_white) = "ReferenceBlackWhite" | A pair of headroom and footroom image data values (codes) for each pixel component.|
317| static const char \*[OHOS_IMAGE_PROPERTY_COPYRIGHT](#ohos_image_property_copyright) = "Copyright" | Copyright notice of the image.|
318| static const char \*[OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT](#ohos_image_property_jpeg_interchange_format) = "JPEGInterchangeFormat" | Offset of the SOI marker of a JPEG interchange format bitstream.|
319| static const char \*[OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT_LENGTH](#ohos_image_property_jpeg_interchange_format_length) = "JPEGInterchangeFormatLength" | Number of bytes of the JPEG stream.|
320| static const char \*[OHOS_IMAGE_PROPERTY_EXPOSURE_PROGRAM](#ohos_image_property_exposure_program) = "ExposureProgram" | Class of the program used by the camera to set exposure when the image was captured.|
321| static const char \*[OHOS_IMAGE_PROPERTY_SPECTRAL_SENSITIVITY](#ohos_image_property_spectral_sensitivity) = "SpectralSensitivity" | Spectral sensitivity of each channel of the camera.|
322| static const char \*[OHOS_IMAGE_PROPERTY_OECF](#ohos_image_property_oecf) = "OECF" | Opto-Electric Conversion Function (OECF) specified in ISO 14524.|
323| static const char \*[OHOS_IMAGE_PROPERTY_EXIF_VERSION](#ohos_image_property_exif_version) = "ExifVersion" | Version of the supported EXIF standard.|
324| static const char \*[OHOS_IMAGE_PROPERTY_DATE_TIME_DIGITIZED](#ohos_image_property_date_time_digitized) = "DateTimeDigitized" | Date and time when the image was stored as digital data, in the format of YYYY:MM:DD HH:MM:SS.|
325| static const char \*[OHOS_IMAGE_PROPERTY_COMPONENTS_CONFIGURATION](#ohos_image_property_components_configuration) = "ComponentsConfiguration" | Specific information about compressed data.|
326| static const char \*[OHOS_IMAGE_PROPERTY_SHUTTER_SPEED_VALUE](#ohos_image_property_shutter_speed_value) = "ShutterSpeedValue" | Shutter speed, expressed in Additive System of Photographic Exposure (APEX) values.|
327| static const char \*[OHOS_IMAGE_PROPERTY_BRIGHTNESS_VALUE](#ohos_image_property_brightness_value) = "BrightnessValue" | Value of brightness, expressed in APEX values.|
328| static const char \*[OHOS_IMAGE_PROPERTY_MAX_APERTURE_VALUE](#ohos_image_property_max_aperture_value) = "MaxApertureValue" | Smallest F number of the lens.|
329| static const char \*[OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE](#ohos_image_property_subject_distance) = "SubjectDistance" | Distance to the subject, in meters.|
330| static const char \*[OHOS_IMAGE_PROPERTY_SUBJECT_AREA](#ohos_image_property_subject_area) = "SubjectArea" | Location and area of the main subject in the entire scene.|
331| static const char \*[OHOS_IMAGE_PROPERTY_MAKER_NOTE](#ohos_image_property_maker_note) = "MakerNote" | Marker used by EXIF/DCF manufacturers to record any required information.|
332| static const char \*[OHOS_IMAGE_PROPERTY_SUBSEC_TIME](#ohos_image_property_subsec_time) = "SubsecTime" | Tag used to record fractions of seconds for the **DateTime** tag.|
333| static const char \*[OHOS_IMAGE_PROPERTY_SUBSEC_TIME_ORIGINAL](#ohos_image_property_subsec_time_original) = "SubsecTimeOriginal" | Tag used to record fractions of seconds for the **DateTimeOriginal** tag.|
334| static const char \*[OHOS_IMAGE_PROPERTY_SUBSEC_TIME_DIGITIZED](#ohos_image_property_subsec_time_digitized) = "SubsecTimeDigitized" | Tag used to record fractions of seconds for the **DateTimeDigitized** tag.|
335| static const char \*[OHOS_IMAGE_PROPERTY_FLASHPIX_VERSION](#ohos_image_property_flashpix_version) = "FlashpixVersion" | FlashPix format version supported by an FPXR file. It is used to enhance device compatibility.|
336| static const char \*[OHOS_IMAGE_PROPERTY_COLOR_SPACE](#ohos_image_property_color_space) = "ColorSpace" | Color space information, which is usually recorded as a color space specifier.|
337| static const char \*[OHOS_IMAGE_PROPERTY_RELATED_SOUND_FILE](#ohos_image_property_related_sound_file) = "RelatedSoundFile" | Name of an audio file related to the image data.|
338| static const char \*[OHOS_IMAGE_PROPERTY_FLASH_ENERGY](#ohos_image_property_flash_energy) = "FlashEnergy" | Strobe energy at the time the image was captured, in Beam Candle Power Seconds (BCPS).|
339| static const char \*[OHOS_IMAGE_PROPERTY_SPATIAL_FREQUENCY_RESPONSE](#ohos_image_property_spatial_frequency_response) = "SpatialFrequencyResponse" | Spatial frequency table of the camera or input device.|
340| static const char \*[OHOS_IMAGE_PROPERTY_FOCAL_PLANE_X_RESOLUTION](#ohos_image_property_focal_plane_x_resolution) = "FocalPlaneXResolution" | Number of pixels in the image width (X) direction per FocalPlaneResolutionUnit.|
341| static const char \*[OHOS_IMAGE_PROPERTY_FOCAL_PLANE_Y_RESOLUTION](#ohos_image_property_focal_plane_y_resolution) = "FocalPlaneYResolution" | Number of pixels in the image height (Y) direction per FocalPlaneResolutionUnit.|
342| static const char \*[OHOS_IMAGE_PROPERTY_FOCAL_PLANE_RESOLUTION_UNIT](#ohos_image_property_focal_plane_resolution_unit) = "FocalPlaneResolutionUnit" | Unit for measuring FocalPlaneXResolution and FocalPlaneYResolution.|
343| static const char \*[OHOS_IMAGE_PROPERTY_SUBJECT_LOCATION](#ohos_image_property_subject_location) = "SubjectLocation" | Location of the main subject relative to the left edge.|
344| static const char \*[OHOS_IMAGE_PROPERTY_EXPOSURE_INDEX](#ohos_image_property_exposure_index) = "ExposureIndex" | Exposure index selected at the time the image is captured.|
345| static const char \*[OHOS_IMAGE_PROPERTY_SENSING_METHOD](#ohos_image_property_sensing_method) = "SensingMethod" | Type of the image sensor on the camera.|
346| static const char \*[OHOS_IMAGE_PROPERTY_FILE_SOURCE](#ohos_image_property_file_source) = "FileSource" | Image source.|
347| static const char \*[OHOS_IMAGE_PROPERTY_CFA_PATTERN](#ohos_image_property_cfa_pattern) = "CFAPattern" | Color Filter Array (CFA) geometric pattern of the image sensor.|
348| static const char \*[OHOS_IMAGE_PROPERTY_CUSTOM_RENDERED](#ohos_image_property_custom_rendered) = "CustomRendered" | Special processing on image data.|
349| static const char \*[OHOS_IMAGE_PROPERTY_EXPOSURE_MODE](#ohos_image_property_exposure_mode) = "ExposureMode" | Exposure mode set when the image was captured.|
350| static const char \*[OHOS_IMAGE_PROPERTY_DIGITAL_ZOOM_RATIO](#ohos_image_property_digital_zoom_ratio) = "DigitalZoomRatio" | Digital zoom ratio when the image was captured.|
351| static const char \*[OHOS_IMAGE_PROPERTY_SCENE_CAPTURE_TYPE](#ohos_image_property_scene_capture_type) = "SceneCaptureType" | Type of the scene that was captured.|
352| static const char \*[OHOS_IMAGE_PROPERTY_GAIN_CONTROL](#ohos_image_property_gain_control) = "GainControl" | Degree of overall image gain adjustment.|
353| static const char \*[OHOS_IMAGE_PROPERTY_CONTRAST](#ohos_image_property_contrast) = "Contrast" | Direction of contrast processing used by the camera.|
354| static const char \*[OHOS_IMAGE_PROPERTY_SATURATION](#ohos_image_property_saturation) = "Saturation" | Direction of saturation processing used by the camera.|
355| static const char \*[OHOS_IMAGE_PROPERTY_SHARPNESS](#ohos_image_property_sharpness) = "Sharpness" | Direction of sharpness processing used by the camera.|
356| static const char \*[OHOS_IMAGE_PROPERTY_DEVICE_SETTING_DESCRIPTION](#ohos_image_property_device_setting_description) = "DeviceSettingDescription" | Information about the photographing conditions of a specific camera model.|
357| static const char \*[OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE_RANGE](#ohos_image_property_subject_distance_range) = "SubjectDistanceRange" | Distance to the subject.|
358| static const char \*[OHOS_IMAGE_PROPERTY_IMAGE_UNIQUE_ID](#ohos_image_property_image_unique_id) = "ImageUniqueID" | Unique identifier assigned to each image.|
359| static const char \*[OHOS_IMAGE_PROPERTY_GPS_VERSION_ID](#ohos_image_property_gps_version_id) = "GPSVersionID" | Version of GPSInfoIFD.|
360| static const char \*[OHOS_IMAGE_PROPERTY_GPS_ALTITUDE_REF](#ohos_image_property_gps_altitude_ref) = "GPSAltitudeRef" | Whether the latitude is north or south latitude.|
361| static const char \*[OHOS_IMAGE_PROPERTY_GPS_ALTITUDE](#ohos_image_property_gps_altitude) = "GPSAltitude" | Altitude based on the reference in GPSAltitudeRef.|
362| static const char \*[OHOS_IMAGE_PROPERTY_GPS_SATELLITES](#ohos_image_property_gps_satellites) = "GPSSatellites" | GPS satellites used for measurement.|
363| static const char \*[OHOS_IMAGE_PROPERTY_GPS_STATUS](#ohos_image_property_gps_status) = "GPSStatus" | Status of the GPS receiver when the image was recorded.|
364| static const char \*[OHOS_IMAGE_PROPERTY_GPS_MEASURE_MODE](#ohos_image_property_gps_measure_mode) = "GPSMeasureMode" | GPS measurement pmode.|
365| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DOP](#ohos_image_property_gps_dop) = "GPSDOP" | GPS DOP (data degree of precision)|
366| static const char \*[OHOS_IMAGE_PROPERTY_GPS_SPEED_REF](#ohos_image_property_gps_speed_ref) = "GPSSpeedRef" | Unit used to express the movement speed of the GPS receiver.|
367| static const char \*[OHOS_IMAGE_PROPERTY_GPS_SPEED](#ohos_image_property_gps_speed) = "GPSSpeed" | Movement speed of the GPS receiver.|
368| static const char \*[OHOS_IMAGE_PROPERTY_GPS_TRACK_REF](#ohos_image_property_gps_track_ref) = "GPSTrackRef" | Reference of the movement direction of the GPS receiver.|
369| static const char \*[OHOS_IMAGE_PROPERTY_GPS_TRACK](#ohos_image_property_gps_track) = "GPSTrack" | Movement direction of the GPS receiver.|
370| static const char \*[OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION_REF](#ohos_image_property_gps_img_direction_ref) = "GPSImgDirectionRef" | Reference of the direction of the image when it was captured.|
371| static const char \*[OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION](#ohos_image_property_gps_img_direction) = "GPSImgDirection" | Direction of the image when it was captured.|
372| static const char \*[OHOS_IMAGE_PROPERTY_GPS_MAP_DATUM](#ohos_image_property_gps_map_datum) = "GPSMapDatum" | Geodetic survey data used by the GPS receiver.|
373| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE_REF](#ohos_image_property_gps_dest_latitude_ref) = "GPSDestLatitudeRef" | Whether the latitude of the destination point is north or south latitude.|
374| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE](#ohos_image_property_gps_dest_latitude) = "GPSDestLatitude" | Latitude of the destination point.|
375| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE_REF](#ohos_image_property_gps_dest_longitude_ref) = "GPSDestLongitudeRef" | Whether the longitude of the destination point is east or west longitude.|
376| static const char \*[OHOS_IMAGE_PROPERTY_GPS_PROCESSING_METHOD](#ohos_image_property_gps_processing_method) = "GPSProcessingMethod" | String that records the name of the method used for positioning.|
377| static const char \*[OHOS_IMAGE_PROPERTY_GPS_AREA_INFORMATION](#ohos_image_property_gps_area_information) = "GPSAreaInformation" | String that records the name of the GPS area.|
378| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DIFFERENTIAL](#ohos_image_property_gps_differential) = "GPSDifferential" | Whether differential correction is applied to the GPS receiver. It is critical to accurate location accuracy.|
379| static const char \*[OHOS_IMAGE_PROPERTY_BODY_SERIAL_NUMBER](#ohos_image_property_body_serial_number) = "BodySerialNumber" | Serial number of the camera body.|
380| static const char \*[OHOS_IMAGE_PROPERTY_CAMERA_OWNER_NAME](#ohos_image_property_camera_owner_name) = "CameraOwnerName" | Name of the camera owner.|
381| static const char \*[OHOS_IMAGE_PROPERTY_COMPOSITE_IMAGE](#ohos_image_property_composite_image) = "CompositeImage" | Whether the image is a composite image.|
382| static const char \*[OHOS_IMAGE_PROPERTY_DNG_VERSION](#ohos_image_property_dng_version) = "DNGVersion" | DNG version. It encodes the DNG 4-tier version number.|
383| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE](#ohos_image_property_gps_dest_longitude) = "GPSDestLongitude" | Longitude of the destination point.|
384| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING_REF](#ohos_image_property_gps_dest_bearing_ref) = "GPSDestBearingRef" | Reference of the bearing to the destination point.|
385| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING](#ohos_image_property_gps_dest_bearing) = "GPSDestBearing" | Bearing to the destination point.|
386| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE_REF](#ohos_image_property_gps_dest_distance_ref) = "GPSDestDistanceRef" | Unit used to express the distance to the destination point.|
387| static const char \*[OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE](#ohos_image_property_gps_dest_distance) = "GPSDestDistance" | Distance to the destination point.|
388| static const char \*[OHOS_IMAGE_PROPERTY_DEFAULT_CROP_SIZE](#ohos_image_property_default_crop_size) = "DefaultCropSize" | Size of the final image area, in raw image coordinates, taking into account extra pixels around the edges of the final image.|
389| static const char \*[OHOS_IMAGE_PROPERTY_GAMMA](#ohos_image_property_gamma) = "Gamma" | Gamma value.|
390| static const char \*[OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEYYY](#ohos_image_property_iso_speed_latitudeyyy) = "ISOSpeedLatitudeyyy" | ISO speed latitude yyy value of the camera or input device, which is defined in ISO 12232.|
391| static const char \*[OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEZZZ](#ohos_image_property_iso_speed_latitudezzz) = "ISOSpeedLatitudezzz" | ISO speed latitude zzz value of the camera or input device, which is defined in ISO 12232.|
392| static const char \*[OHOS_IMAGE_PROPERTY_LENS_MAKE](#ohos_image_property_lens_make) = "LensMake" | Manufacturer of the lens.|
393| static const char \*[OHOS_IMAGE_PROPERTY_LENS_MODEL](#ohos_image_property_lens_model) = "LensModel" | Model of the lens.|
394| static const char \*[OHOS_IMAGE_PROPERTY_LENS_SERIAL_NUMBER](#ohos_image_property_lens_serial_number) = "LensSerialNumber" | Serial number of the lens.|
395| static const char \*[OHOS_IMAGE_PROPERTY_LENS_SPECIFICATION](#ohos_image_property_lens_specification) = "LensSpecification" | Specifications of the lens.|
396| static const char \*[OHOS_IMAGE_PROPERTY_NEW_SUBFILE_TYPE](#ohos_image_property_new_subfile_type) = "NewSubfileType" | Data type of a subfile, such as a full-resolution image, a thumbnail, or a part of a multi-frame image. The value is a bit mask. The value 0 indicates a full-resolution image, **1** indicates a thumbnail, and **2** indicates a part of a multi-frame image.|
397| static const char \*[OHOS_IMAGE_PROPERTY_OFFSET_TIME](#ohos_image_property_offset_time) = "OffsetTime" | Time with an offset from UTC when the image was captured, in the format of ��HH:MM.|
398| static const char \*[OHOS_IMAGE_PROPERTY_OFFSET_TIME_DIGITIZED](#ohos_image_property_offset_time_digitized) = "OffsetTimeDigitized" | Time with an offset from UTC when the image was digitized. It helps to accurately adjust the timestamp.|
399| static const char \*[OHOS_IMAGE_PROPERTY_OFFSET_TIME_ORIGINAL](#ohos_image_property_offset_time_original) = "OffsetTimeOriginal" | Time with an offset from UTC when the original image was created. It is critical for time-sensitive applications.|
400| static const char \*[OHOS_IMAGE_PROPERTY_SOURCE_EXPOSURE_TIMES_OF_COMPOSITE_IMAGE](#ohos_image_property_source_exposure_times_of_composite_image) = "SourceExposureTimesOfCompositeImage" | Exposure time of source images of the composite image.|
401| static const char \*[OHOS_IMAGE_PROPERTY_SOURCE_IMAGE_NUMBER_OF_COMPOSITE_IMAGE](#ohos_image_property_source_image_number_of_composite_image) = "SourceImageNumberOfCompositeImage" | Number of source images of the composite image.|
402| static const char \*[OHOS_IMAGE_PROPERTY_SUBFILE_TYPE](#ohos_image_property_subfile_type) = "SubfileType" | Type of data contained in this subfile. This tag has been deprecated. Use **NewSubfileType** instead.|
403| static const char \*[OHOS_IMAGE_PROPERTY_GPS_H_POSITIONING_ERROR](#ohos_image_property_gps_h_positioning_error) = "GPSHPositioningError" | Horizontal positioning error, in meters.|
404| static const char \*[OHOS_IMAGE_PROPERTY_PHOTOGRAPHIC_SENSITIVITY](#ohos_image_property_photographic_sensitivity) = "PhotographicSensitivity" | Sensitivity of the camera or input device when the image was captured.|
405| static const char \*[OHOS_IMAGE_PROPERTY_BURST_NUMBER](#ohos_image_property_burst_number) = "HwMnoteBurstNumber" | Number of burst shooting times.|
406| static const char \*[OHOS_IMAGE_PROPERTY_FACE_CONF](#ohos_image_property_face_conf) = "HwMnoteFaceConf" | Face confidence.|
407| static const char \*[OHOS_IMAGE_PROPERTY_FACE_LEYE_CENTER](#ohos_image_property_face_leye_center) = "HwMnoteFaceLeyeCenter" | Left eye centered. It is used in [OH_ImageSource_GetImageProperty](#oh_imagesourcenative_getimageproperty) and [OH_ImageSource_ModifyImageProperty](#oh_imagesourcenative_modifyimageproperty).|
408| static const char \*[OHOS_IMAGE_PROPERTY_FACE_MOUTH_CENTER](#ohos_image_property_face_mouth_center) = "HwMnoteFaceMouthCenter" | Mouth centered.|
409| static const char \*[OHOS_IMAGE_PROPERTY_FACE_POINTER](#ohos_image_property_face_pointer) = "HwMnoteFacePointer" | Face pointer.|
410| static const char \*[OHOS_IMAGE_PROPERTY_FACE_RECT](#ohos_image_property_face_rect) = "HwMnoteFaceRect" | Face rectangle.|
411| static const char \*[OHOS_IMAGE_PROPERTY_FACE_REYE_CENTER](#ohos_image_property_face_reye_center) = "HwMnoteFaceReyeCenter" | Right eye centered.|
412| static const char \*[OHOS_IMAGE_PROPERTY_FACE_SMILE_SCORE](#ohos_image_property_face_smile_score) = "HwMnoteFaceSmileScore" | Smile score of for faces.|
413| static const char \*[OHOS_IMAGE_PROPERTY_FACE_VERSION](#ohos_image_property_face_version) = "HwMnoteFaceVersion" | Facial recognition algorithm version.|
414| static const char \*[OHOS_IMAGE_PROPERTY_FRONT_CAMERA](#ohos_image_property_front_camera) = "HwMnoteFrontCamera" | Whether the front camera is used to take a selfie.|
415| static const char \*[OHOS_IMAGE_PROPERTY_SCENE_POINTER](#ohos_image_property_scene_pointer) = "HwMnoteScenePointer" | Pointer to the scene.|
416| static const char \*[OHOS_IMAGE_PROPERTY_SCENE_VERSION](#ohos_image_property_scene_version) = "HwMnoteSceneVersion" | Scene algorithm version.|
417| static const char \*[OHOS_IMAGE_PROPERTY_GIF_LOOP_COUNT](#ohos_image_property_gif_loop_count) = "GIFLoopCount" | Number of GIF loops.|
418| static const char \*[OHOS_IMAGE_PROPERTY_X_IN_ORIGINAL](#ohos_image_property_x_in_original) = "XInOriginal" | X coordinate of the upper left corner of the fragment map in the original image. |
419| static const char \*[OHOS_IMAGE_PROPERTY_Y_IN_ORIGINAL](#ohos_image_property_y_in_original) = "XInOriginal" | Y coordinate of the upper left corner of the fragment map in the original image. |
420| static const char \*[OHOS_IMAGE_PROPERTY_FRAGMENT_WIDTH](#ohos_image_property_fragment_width) = "FragmentImageWidth"| Width of the fragment map. |
421| static const char \*[OHOS_IMAGE_PROPERTY_FRAGMENT_HEIGHT](#ohos_image_property_fragment_height) = "FragmentImageHeight" | Height of the fragment map. |
422
423
424## Type Description
425
426
427### Image_MimeType
428
429```
430typedef struct Image_String Image_MimeType
431```
432
433**Description**
434
435Defines a struct for an image format type.
436
437**Since**: 12
438
439
440### Image_Region
441
442```
443typedef struct Image_Region Image_Region
444```
445
446**Description**
447
448Defines a struct for the region of an image to decode.
449
450**Since**: 12
451
452
453### Image_Size
454
455```
456typedef struct Image_Size Image_Size
457```
458
459**Description**
460
461Defines a struct for the image size.
462
463**Since**: 12
464
465
466### Image_String
467
468```
469typedef struct Image_String Image_String
470```
471
472**Description**
473
474Defines a struct for an image string.
475
476**Since**: 12
477
478
479### OH_AuxiliaryPictureInfo
480
481```
482typedef struct OH_AuxiliaryPictureInfo OH_AuxiliaryPictureInfo
483```
484
485**Description**
486
487Defines a struct for the auxiliary picture information, which is used to perform operations related to the auxiliary picture information.
488
489**Since**: 13
490
491
492### OH_AuxiliaryPictureNative
493
494```
495typedef struct OH_AuxiliaryPictureNative OH_AuxiliaryPictureNative
496```
497
498**Description**
499
500Defines a struct for the auxiliary picture, which is used to perform operations related to the auxiliary picture.
501
502**Since**: 13
503
504
505### OH_DecodingOptions
506
507```
508typedef struct OH_DecodingOptions OH_DecodingOptions
509```
510
511**Description**
512
513Defines a struct for decoding parameters, which are used in [OH_ImageSourceNative_CreatePixelmap](#oh_imagesourcenative_createpixelmap).
514
515The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_DecodingOptions Struct](../../media/image/image-structure-c.md#oh_decodingoptions-struct).
516
517**Since**: 12
518
519
520### OH_ImageNative
521
522```
523typedef struct OH_ImageNative OH_ImageNative
524```
525
526**Description**
527
528Defines the alias for an image object at the native layer.
529
530The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImageNative Struct](../../media/image/image-structure-c.md#oh_imagenative-struct).
531
532**Since**: 12
533
534
535### OH_ImagePackerNative
536
537```
538typedef struct OH_ImagePackerNative OH_ImagePackerNative
539```
540
541**Description**
542
543Defines a struct for the image packer, which is used to perform operations related to an image packer.
544
545The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImagePackerNative Struct](../../media/image/image-structure-c.md#oh_imagepackernative-struct).
546
547**Since**: 12
548
549
550### OH_ImageReceiver_OnCallback
551
552```
553typedef void(* OH_ImageReceiver_OnCallback) (OH_ImageReceiverNative *receiver)
554```
555
556**Description**
557
558Defines the callbacks for the image receiver at the native layer.
559
560**Since**: 12
561
562
563### OH_ImageReceiverNative
564
565```
566typedef struct OH_ImageReceiverNative OH_ImageReceiverNative
567```
568
569**Description**
570
571Defines the data type name of the image receiver at the native layer.
572
573The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImageReceiverNative Struct](../../media/image/image-structure-c.md#oh_imagereceivernative-struct).
574
575**Since**: 12
576
577
578### OH_ImageReceiverOptions
579
580```
581typedef struct OH_ImageReceiverOptionsOH_ImageReceiverOptions
582```
583
584**Description**
585
586Defines the data type name of the image receiver options.
587
588The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImageReceiverOptions Struct](../../media/image/image-structure-c.md#oh_imagereceiveroptions-struct).
589
590**Since**: 12
591
592
593### OH_ImageSource_Info
594
595```
596typedef struct OH_ImageSource_Info OH_ImageSource_Info
597```
598
599**Description**
600
601Defines a struct for the image source information, which is created by calling [OH_ImageSourceInfo_Create](#oh_imagesourceinfo_create).
602
603The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImageSource_Info Struct](../../media/image/image-structure-c.md#oh_imagesource_info-struct).
604
605**Since**: 12
606
607
608### OH_ImageSourceNative
609
610```
611typedef struct OH_ImageSourceNative OH_ImageSourceNative
612```
613
614**Description**
615
616Defines a struct for the image source, which is used to perform operations related to an image source.
617
618The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_ImageSourceNative Struct](../../media/image/image-structure-c.md#oh_imagesourcenative-struct).
619
620**Since**: 12
621
622
623### OH_NativeColorSpaceManager
624
625```
626typedef struct OH_NativeColorSpaceManager OH_NativeColorSpaceManager
627```
628
629**Description**
630
631Defines a struct for the native color space manager, which is used to perform operations related to the native color space manager.
632
633**Since**: 13
634
635
636### OH_PackingOptions
637
638```
639typedef struct OH_PackingOptions OH_PackingOptions
640```
641
642**Description**
643
644Defines a struct for image encoding parameters.
645
646The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_PackingOptions Struct](../../media/image/image-structure-c.md#oh_packingoptions-struct).
647
648**Since**: 12
649
650
651### OH_PackingOptionsForSequence
652
653```
654typedef struct OH_PackingOptionsForSequence OH_PackingOptionsForSequence
655```
656
657**Description**
658
659Defines a struct for image sequence encoding parameters.
660
661**Since**: 13
662
663
664### OH_PictureMetadata
665
666```
667typedef struct OH_PictureMetadata OH_PictureMetadata
668```
669
670**Description**
671
672Defines a struct for the picture metadata.
673
674**Since**: 13
675
676
677### OH_PictureNative
678
679```
680typedef struct OH_PictureNativeOH_PictureNative
681```
682
683**Description**
684
685Defines a struct for the picture, which is used to perform operations related to the picture.
686
687**Since**: 13
688
689
690### OH_Pixelmap_HdrDynamicMetadata
691
692```
693typedef struct OH_Pixelmap_HdrDynamicMetadata OH_Pixelmap_HdrDynamicMetadata
694```
695
696**Description**
697
698Defines a struct for the dynamic metadata values available for the key **DR_DYNAMIC_METADATA**.
699
700**Since**: 12
701
702
703### OH_Pixelmap_HdrGainmapMetadata
704
705```
706typedef struct OH_Pixelmap_HdrGainmapMetadata OH_Pixelmap_HdrGainmapMetadata
707```
708
709**Description**
710
711Defines a struct for the gain map metadata values available for the key **HDR_GAINMAP_METADATA**. For details, see ISO 21496-1.
712
713**Since**: 12
714
715
716### OH_Pixelmap_HdrMetadataValue
717
718```
719typedef struct OH_Pixelmap_HdrMetadataValue OH_Pixelmap_HdrMetadataValue
720```
721
722**Description**
723
724Defines a struct for the HDR metadata values used by the PixelMap and available for the key [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey).
725
726It is used in [OH_PixelmapNative_SetMetadata](#oh_pixelmapnative_setmetadata) and [OH_PixelmapNative_GetMetadata](#oh_pixelmapnative_getmetadata).
727
728**Since**: 12
729
730
731### OH_Pixelmap_HdrStaticMetadata
732
733```
734typedef struct OH_Pixelmap_HdrStaticMetadata OH_Pixelmap_HdrStaticMetadata
735```
736
737**Description**
738
739Defines a struct for the static metadata values available for the key **HDR_STATIC_METADATA**.
740
741**Since**: 12
742
743
744### OH_Pixelmap_ImageInfo
745
746```
747typedef struct OH_Pixelmap_ImageInfo OH_Pixelmap_ImageInfo
748```
749
750**Description**
751
752Defines a struct for the image information.
753
754The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_Pixelmap_ImageInfo Struct](../../media/image/image-structure-c.md#oh_pixelmap_imageinfo-struct).
755
756**Since**: 12
757
758
759### OH_Pixelmap_InitializationOptions
760
761```
762typedef struct OH_Pixelmap_InitializationOptions OH_Pixelmap_InitializationOptions
763```
764
765**Description**
766
767Defines a struct for the initialization parameters.
768
769The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_Pixelmap_InitializationOptions Struct](../../media/image/image-structure-c.md#oh_pixelmap_initializationoptions-struct).
770
771**Since**: 12
772
773
774### OH_PixelmapNative
775
776```
777typedef struct OH_PixelmapNative OH_PixelmapNative
778```
779
780**Description**
781
782Defines a struct for the PixelMap, which is used to perform operations related to a PixelMap.
783
784The fields in this struct cannot be directly operated. Instead, they must be manipulated via function calls. For details about the struct content and operation mode, see [OH_PixelmapNative Struct](../../media/image/image-structure-c.md#oh_pixelmapnative-struct).
785
786**Since**: 12
787
788
789### OH_NativeBuffer
790
791```
792typedef struct OH_NativeBuffer OH_NativeBuffer
793```
794
795**Description**
796
797Defines a struct for the native buffer, which is used to perform operations related to the native buffer.
798
799
800**Since**: 12
801
802
803## Enum Description
804
805
806### Image_AuxiliaryPictureType
807
808```
809enum Image_AuxiliaryPictureType
810```
811
812**Description**
813
814Enumerates the auxiliary picture types.
815
816**Since**: 13
817
818| Value| Description|
819| -------- | -------- |
820| AUXILIARY_PICTURE_TYPE_GAINMAP  | Gain map, a mechanism for transforming an SDR image into an HDR image capable of adjustable display adjustment. It is a set of combinations describing how to apply gain map metadata.  |
821| AUXILIARY_PICTURE_TYPE_DEPTH_MAP  | Depth map, which stores the depth data of an image. It captures the distance between each pixel and the camera to provide 3D scene structure. It is usually used for 3D modeling and scene comprehension.  |
822| AUXILIARY_PICTURE_TYPE_UNREFOCUS_MAP  | Defocused portrait original image, which provides a method to emphasize background blur in portrait photographing. It helps users select a focus region in post-processing, allowing for greater creative control.  |
823| AUXILIARY_PICTURE_TYPE_LINEAR_MAP  | Linear map, which is used to provide additional viewpoints or supplementary information. It is usually used to enhance visual effects and can contain linear representations of lighting, colors, or other visual elements in a scene.  |
824| AUXILIARY_PICTURE_TYPE_FRAGMENT_MAP  | Fragment map, which indicates regions obscured by watermarks in the original image. It is used to remove or correct the watermark interference, thereby enhancing the image completeness and visibility.  |
825
826
827### IMAGE_DYNAMIC_RANGE
828
829```
830enum IMAGE_DYNAMIC_RANGE
831```
832
833**Description**
834
835Enumerates the desired dynamic range for decoding.
836
837**Since**: 12
838
839| Value| Description|
840| -------- | -------- |
841| IMAGE_DYNAMIC_RANGE_AUTO  | Adaptive processing.  |
842| IMAGE_DYNAMIC_RANGE_SDR  | Standard dynamic range (SDR).  |
843| IMAGE_DYNAMIC_RANGE_HDR  | High dynamic range (HDR).  |
844
845
846### Image_ErrorCode
847
848```
849enum Image_ErrorCode
850```
851
852**Description**
853
854Enumerates the error codes.
855
856**Since**: 12
857
858| Value| Description|
859| -------- | -------- |
860| IMAGE_SUCCESS  | Operation successful.|
861| IMAGE_BAD_PARAMETER  | Invalid parameter.|
862| IMAGE_UNSUPPORTED_MIME_TYPE  | Unsupported MIME type.|
863| IMAGE_UNKNOWN_MIME_TYPE  | Unknown MIME type.|
864| IMAGE_TOO_LARGE  | The data or image is too large.|
865| IMAGE_DMA_NOT_EXIST  | The memory is not the DMA memory.|
866| IMAGE_DMA_OPERATION_FAILED  | The operation on the DMA memory fails.|
867| IMAGE_UNSUPPORTED_OPERATION  | Unsupported operation.|
868| IMAGE_UNSUPPORTED_METADATA  | Unsupported metadata.|
869| IMAGE_UNSUPPORTED_CONVERSION  | Unsupported conversion.|
870| IMAGE_INVALID_REGION  | Invalid region.|
871| IMAGE_UNSUPPORTED_MEMORY_FORMAT  | The memory format is not supported.<br>**Since**: 13|
872| IMAGE_ALLOC_FAILED  | Failed to allocate the memory.|
873| IMAGE_COPY_FAILED  | Failed to copy the memory.|
874| IMAGE_UNKNOWN_ERROR  | Unknown error.|
875| IMAGE_BAD_SOURCE  | Abnormal data source.|
876| IMAGE_DECODE_FAILED  | Decoding failed.|
877| IMAGE_ENCODE_FAILED  | Encoding failed.|
878
879
880### Image_MetadataType
881
882```
883enum Image_MetadataType
884```
885
886**Description**
887
888Enumerates the metadata types.
889
890**Since**: 13
891
892| Value| Description|
893| -------- | -------- |
894| EXIF_METADATA  | Exif metadata.  |
895| FRAGMENT_METADATA  | Fragment map metadata.  |
896
897
898### IMAGE_PACKER_DYNAMIC_RANGE
899
900```
901enum IMAGE_PACKER_DYNAMIC_RANGE
902```
903
904**Description**
905
906Enumerates the desired dynamic range for encoding.
907
908**Since**: 12
909
910| Value| Description|
911| -------- | -------- |
912| IMAGE_PACKER_DYNAMIC_RANGE_AUTO  | Adaptive processing.  |
913| IMAGE_PACKER_DYNAMIC_RANGE_SDR  | SDR.  |
914
915
916### PIXEL_FORMAT
917
918```
919enum PIXEL_FORMAT
920```
921
922**Description**
923
924Enumerates the image pixel formats.
925
926**Since**: 12
927
928| Value| Description|
929| -------- | -------- |
930| PIXEL_FORMAT_UNKNOWN | Unknown format.|
931| PIXEL_FORMAT_RGB_565 | RGB_565 format.|
932| PIXEL_FORMAT_RGBA_8888 | RGBA_8888 format.|
933| PIXEL_FORMAT_BGRA_8888 | BGRA_8888 format.|
934| PIXEL_FORMAT_RGB_888 | RGB_888 format.|
935| PIXEL_FORMAT_ALPHA_8 | ALPHA_8 format.|
936| PIXEL_FORMAT_RGBA_F16 | RGBA_F16 format.|
937| PIXEL_FORMAT_NV21 | NV21 format.|
938| PIXEL_FORMAT_NV12 | NV12 format.|
939
940
941### OH_Pixelmap_HdrMetadataKey
942
943```
944enum OH_Pixelmap_HdrMetadataKey
945```
946
947**Description**
948
949Enumerates the keys of the HDR related metadata information used by the PixelMap. It is used in [OH_PixelmapNative_SetMetadata](#oh_pixelmapnative_setmetadata) and [OH_PixelmapNative_GetMetadata](#oh_pixelmapnative_getmetadata).
950
951**Since**: 12
952
953| Value| Description|
954| -------- | -------- |
955| HDR_METADATA_TYPE  | Metadata type used by the PixelMap.  |
956| HDR_STATIC_METADATA  | Static metadata.  |
957| HDR_DYNAMIC_METADATA  | Dynamic metadata.  |
958| HDR_GAINMAP_METADATA  | Metadata used by gain maps.  |
959
960
961### OH_Pixelmap_HdrMetadataType
962
963```
964enum OH_Pixelmap_HdrMetadataType
965```
966
967**Description**
968
969Enumerates the HDR metadata types, which are the values of **HDR_METADATA_TYPE**.
970
971**Since**: 12
972
973| Value| Description|
974| -------- | -------- |
975| HDR_METADATA_TYPE_NONE  | No metadata.  |
976| HDR_METADATA_TYPE_BASE  | Metadata used for base graphics.  |
977| HDR_METADATA_TYPE_GAINMAP  | Metadata used for gain maps.  |
978| HDR_METADATA_TYPE_ALTERNATE  | Metadata used for synthesized HDR graphics.  |
979
980
981### OH_PixelmapNative_AntiAliasingLevel
982
983```
984enum OH_PixelmapNative_AntiAliasingLevel
985```
986
987**Description**
988
989Enumerates the anti-aliasing levels used for scaling PixelMaps.
990
991**Since**: 12
992
993| Value| Description|
994| -------- | -------- |
995| OH_PixelmapNative_AntiAliasing_NONE  | Nearest neighbor interpolation.  |
996| OH_PixelmapNative_AntiAliasing_LOW  | Bilinear interpolation.  |
997| OH_PixelmapNative_AntiAliasing_MEDIUM  | Bilinear interpolation with mipmap enabled. You are advised to use this value when zooming out an image.  |
998| OH_PixelmapNative_AntiAliasing_HIGH  | Cubic interpolation.  |
999
1000
1001### PIXELMAP_ALPHA_TYPE
1002
1003```
1004enum PIXELMAP_ALPHA_TYPE
1005```
1006
1007**Description**
1008
1009Enumerates the alpha types of a PixelMap.
1010
1011**Since**: 12
1012
1013| Value| Description|
1014| -------- | -------- |
1015| PIXELMAP_ALPHA_TYPE_UNKNOWN | Unknown format.|
1016| PIXELMAP_ALPHA_TYPE_OPAQUE | Opaque format.|
1017| PIXELMAP_ALPHA_TYPE_PREMULTIPLIED | Premultiplied format.|
1018
1019
1020## Function Description
1021
1022
1023### OH_AuxiliaryPictureInfo_Create()
1024
1025```
1026Image_ErrorCode OH_AuxiliaryPictureInfo_Create(OH_AuxiliaryPictureInfo **info)
1027```
1028
1029**Description**
1030
1031Creates an **OH_AuxiliaryPictureInfo** object.
1032
1033**Since**: 13
1034
1035**Parameters**
1036
1037| Name| Description|
1038| -------- | -------- |
1039| info | Double pointer to the **OH_AuxiliaryPictureInfo** object created. |
1040
1041**Returns**
1042
1043Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1044
1045
1046### OH_AuxiliaryPictureInfo_GetPixelFormat()
1047
1048```
1049Image_ErrorCode OH_AuxiliaryPictureInfo_GetPixelFormat(OH_AuxiliaryPictureInfo *info, PIXEL_FORMAT *pixelFormat)
1050```
1051
1052**Description**
1053
1054Obtains the pixel format of an auxiliary picture.
1055
1056**Since**: 13
1057
1058**Parameters**
1059
1060| Name| Description|
1061| -------- | -------- |
1062| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1063| pixelFormat | Pointer to the pixel format obtained. |
1064
1065**Returns**
1066
1067Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1068
1069
1070### OH_AuxiliaryPictureInfo_GetRowStride()
1071
1072```
1073Image_ErrorCode OH_AuxiliaryPictureInfo_GetRowStride(OH_AuxiliaryPictureInfo *info, uint32_t *rowStride)
1074```
1075
1076**Description**
1077
1078Obtains the row stride of an auxiliary picture.
1079
1080**Since**: 13
1081
1082**Parameters**
1083
1084| Name| Description|
1085| -------- | -------- |
1086| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1087| rowStride | Pointer to the row stride, which is the number of bytes from one row of pixels in memory to the next row of pixels in memory. |
1088
1089**Returns**
1090
1091Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1092
1093
1094### OH_AuxiliaryPictureInfo_GetSize()
1095
1096```
1097Image_ErrorCode OH_AuxiliaryPictureInfo_GetSize(OH_AuxiliaryPictureInfo *info, Image_Size *size)
1098```
1099
1100**Description**
1101
1102Obtains the size of an auxiliary picture.
1103
1104**Since**: 13
1105
1106**Parameters**
1107
1108| Name| Description|
1109| -------- | -------- |
1110| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1111| size | Pointer to the size. |
1112
1113**Returns**
1114
1115Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1116
1117
1118### OH_AuxiliaryPictureInfo_GetType()
1119
1120```
1121Image_ErrorCode OH_AuxiliaryPictureInfo_GetType(OH_AuxiliaryPictureInfo *info, Image_AuxiliaryPictureType *type)
1122```
1123
1124**Description**
1125
1126Obtains the auxiliary picture type from the auxiliary picture information.
1127
1128**Since**: 13
1129
1130**Parameters**
1131
1132| Name| Description|
1133| -------- | -------- |
1134| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1135| type | Pointer to the type of the auxiliary picture. |
1136
1137**Returns**
1138
1139Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1140
1141
1142### OH_AuxiliaryPictureInfo_Release()
1143
1144```
1145Image_ErrorCode OH_AuxiliaryPictureInfo_Release(OH_AuxiliaryPictureInfo *info)
1146```
1147
1148**Description**
1149
1150Releases the pointer to an **OH_AuxiliaryPictureInfo** object.
1151
1152**Since**: 13
1153
1154**Parameters**
1155
1156| Name| Description|
1157| -------- | -------- |
1158| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1159
1160**Returns**
1161
1162Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1163
1164
1165### OH_AuxiliaryPictureInfo_SetPixelFormat()
1166
1167```
1168Image_ErrorCode OH_AuxiliaryPictureInfo_SetPixelFormat(OH_AuxiliaryPictureInfo *info, PIXEL_FORMAT pixelFormat)
1169```
1170
1171**Description**
1172
1173Sets the pixel format of an auxiliary picture.
1174
1175**Since**: 13
1176
1177**Parameters**
1178
1179| Name| Description|
1180| -------- | -------- |
1181| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1182| pixelFormat | Pixel format. |
1183
1184**Returns**
1185
1186Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1187
1188
1189### OH_AuxiliaryPictureInfo_SetRowStride()
1190
1191```
1192Image_ErrorCode OH_AuxiliaryPictureInfo_SetRowStride(OH_AuxiliaryPictureInfo *info, uint32_t rowStride)
1193```
1194
1195**Description**
1196
1197Sets the row stride of an auxiliary picture.
1198
1199**Since**: 13
1200
1201**Parameters**
1202
1203| Name| Description|
1204| -------- | -------- |
1205| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1206| rowStride | Row stride, which is the number of bytes from one row of pixels in memory to the next row of pixels in memory. |
1207
1208**Returns**
1209
1210Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1211
1212
1213### OH_AuxiliaryPictureInfo_SetSize()
1214
1215```
1216Image_ErrorCode OH_AuxiliaryPictureInfo_SetSize(OH_AuxiliaryPictureInfo *info, Image_Size *size)
1217```
1218
1219**Description**
1220
1221Sets the size of an auxiliary picture.
1222
1223**Since**: 13
1224
1225**Parameters**
1226
1227| Name| Description|
1228| -------- | -------- |
1229| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1230| size | Pointer to the size. |
1231
1232**Returns**
1233
1234Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1235
1236
1237### OH_AuxiliaryPictureInfo_SetType()
1238
1239```
1240Image_ErrorCode OH_AuxiliaryPictureInfo_SetType(OH_AuxiliaryPictureInfo *info, Image_AuxiliaryPictureType type)
1241```
1242
1243**Description**
1244
1245Sets the auxiliary picture type in the auxiliary picture information.
1246
1247**Since**: 13
1248
1249**Parameters**
1250
1251| Name| Description|
1252| -------- | -------- |
1253| info | Pointer to an **OH_AuxiliaryPictureInfo** object. |
1254| type | Type of the auxiliary picture. |
1255
1256**Returns**
1257
1258Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1259
1260
1261### OH_AuxiliaryPictureNative_Create()
1262
1263```
1264Image_ErrorCode OH_AuxiliaryPictureNative_Create(uint8_t *data, size_t dataLength, Image_Size *size, Image_AuxiliaryPictureType type, OH_AuxiliaryPictureNative **auxiliaryPicture)
1265```
1266
1267**Description**
1268
1269Creates the pointer to an **OH_AuxiliaryPictureNative** object.
1270
1271**Since**: 13
1272
1273**Parameters**
1274
1275| Name| Description|
1276| -------- | -------- |
1277| data | Pointer to the image data. |
1278| dataLength | Length of the image data. |
1279| size | Pointer to the size of the auxiliary picture. |
1280| type | Type of the auxiliary picture. |
1281| auxiliaryPicture | Double pointer to the **OH_AuxiliaryPictureNative** object created. |
1282
1283**Returns**
1284
1285Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1286
1287
1288### OH_AuxiliaryPictureNative_GetInfo()
1289
1290```
1291Image_ErrorCode OH_AuxiliaryPictureNative_GetInfo(OH_AuxiliaryPictureNative *auxiliaryPicture, OH_AuxiliaryPictureInfo **info)
1292```
1293
1294**Description**
1295
1296Obtains the auxiliary picture information.
1297
1298**Since**: 13
1299
1300**Parameters**
1301
1302| Name| Description|
1303| -------- | -------- |
1304| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1305| info | Double pointer to the auxiliary picture information. |
1306
1307**Returns**
1308
1309Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1310
1311
1312### OH_AuxiliaryPictureNative_GetMetadata()
1313
1314```
1315Image_ErrorCode OH_AuxiliaryPictureNative_GetMetadata(OH_AuxiliaryPictureNative *auxiliaryPicture, Image_MetadataType metadataType, OH_PictureMetadata **metadata)
1316```
1317
1318**Description**
1319
1320Obtains the metadata of an auxiliary picture.
1321
1322**Since**: 13
1323
1324**Parameters**
1325
1326| Name| Description|
1327| -------- | -------- |
1328| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1329| metadataType | Metadata type. |
1330| metadata | Double pointer to the metadata. |
1331
1332**Returns**
1333
1334Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported or the metadata type does not match the auxiliary picture type. For details, see [Image_ErrorCode](#image_errorcode).
1335
1336
1337### OH_AuxiliaryPictureNative_GetType()
1338
1339```
1340Image_ErrorCode OH_AuxiliaryPictureNative_GetType(OH_AuxiliaryPictureNative *auxiliaryPicture, Image_AuxiliaryPictureType *type)
1341```
1342
1343**Description**
1344
1345Obtains the type of an auxiliary picture.
1346
1347**Since**: 13
1348
1349**Parameters**
1350
1351| Name| Description|
1352| -------- | -------- |
1353| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1354| type | Type of the auxiliary picture. |
1355
1356**Returns**
1357
1358Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1359
1360
1361### OH_AuxiliaryPictureNative_ReadPixels()
1362
1363```
1364Image_ErrorCode OH_AuxiliaryPictureNative_ReadPixels(OH_AuxiliaryPictureNative *auxiliaryPicture, uint8_t *destination, size_t *bufferSize)
1365```
1366
1367**Description**
1368
1369Reads the pixels of an auxiliary picture and writes the result to the buffer.
1370
1371**Since**: 13
1372
1373**Parameters**
1374
1375| Name| Description|
1376| -------- | -------- |
1377| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1378| destination | Pointer to the buffer to which the pixels of the auxiliary data will be written. |
1379| bufferSize | Pointer to the buffer size. |
1380
1381**Returns**
1382
1383Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_ALLOC_FAILED** if the memory allocation fails; returns **IMAGE_COPY_FAILED** if the memory copy fails. For details, see [Image_ErrorCode](#image_errorcode).
1384
1385
1386### OH_AuxiliaryPictureNative_Release()
1387
1388```
1389Image_ErrorCode OH_AuxiliaryPictureNative_Release(OH_AuxiliaryPictureNative *picture)
1390```
1391
1392**Description**
1393
1394Releases the pointer to an **OH_AuxiliaryPictureNative** object.
1395
1396**Since**: 13
1397
1398**Parameters**
1399
1400| Name| Description|
1401| -------- | -------- |
1402| picture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1403
1404**Returns**
1405
1406Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1407
1408
1409### OH_AuxiliaryPictureNative_SetInfo()
1410
1411```
1412Image_ErrorCode OH_AuxiliaryPictureNative_SetInfo(OH_AuxiliaryPictureNative *auxiliaryPicture, OH_AuxiliaryPictureInfo *info)
1413```
1414
1415**Description**
1416
1417Sets the auxiliary picture information.
1418
1419**Since**: 13
1420
1421**Parameters**
1422
1423| Name| Description|
1424| -------- | -------- |
1425| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1426| info | Pointer to the auxiliary picture information. |
1427
1428**Returns**
1429
1430Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1431
1432
1433### OH_AuxiliaryPictureNative_SetMetadata()
1434
1435```
1436Image_ErrorCode OH_AuxiliaryPictureNative_SetMetadata(OH_AuxiliaryPictureNative *auxiliaryPicture, Image_MetadataType metadataType, OH_PictureMetadata *metadata)
1437```
1438
1439**Description**
1440
1441Sets the metadata for an auxiliary picture.
1442
1443**Since**: 13
1444
1445**Parameters**
1446
1447| Name| Description|
1448| -------- | -------- |
1449| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1450| metadataType | Metadata type. |
1451| metadata | Pointer to the metadata. |
1452
1453**Returns**
1454
1455Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported or the metadata type does not match the auxiliary picture type. For details, see [Image_ErrorCode](#image_errorcode).
1456
1457
1458### OH_AuxiliaryPictureNative_WritePixels()
1459
1460```
1461Image_ErrorCode OH_AuxiliaryPictureNative_WritePixels(OH_AuxiliaryPictureNative *auxiliaryPicture, uint8_t *source, size_t bufferSize)
1462```
1463
1464**Description**
1465
1466Reads the pixels in the buffer and writes the result to an auxiliary picture.
1467
1468**Since**: 13
1469
1470**Parameters**
1471
1472| Name| Description|
1473| -------- | -------- |
1474| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
1475| source | Pixels to be written. |
1476| bufferSize | Buffer size. |
1477
1478**Returns**
1479
1480Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_ALLOC_FAILED** if the memory allocation fails; returns **IMAGE_COPY_FAILED** if the memory copy fails. For details, see [Image_ErrorCode](#image_errorcode).
1481
1482
1483### OH_DecodingOptions_Create()
1484
1485```
1486Image_ErrorCode OH_DecodingOptions_Create(OH_DecodingOptions **options)
1487```
1488
1489**Description**
1490
1491Creates the pointer to an **OH_DecodingOptions** struct.
1492
1493**Since**: 12
1494
1495**Parameters**
1496
1497| Name| Description|
1498| -------- | -------- |
1499| options | Double pointer to the [OH_DecodingOptions](#oh_decodingoptions) struct created. |
1500
1501**Returns**
1502
1503Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1504
1505
1506### OH_DecodingOptions_GetDesiredDynamicRange()
1507
1508```
1509Image_ErrorCode OH_DecodingOptions_GetDesiredDynamicRange(OH_DecodingOptions *options, int32_t *desiredDynamicRange)
1510```
1511
1512**Description**
1513
1514Obtains the desired dynamic range configured during decoding.
1515
1516**Since**: 12
1517
1518**Parameters**
1519
1520| Name| Description|
1521| -------- | -------- |
1522| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1523| desiredDynamicRange | Pointer to the desired dynamic range. For details about the available options, see [IMAGE_DYNAMIC_RANGE](#image_dynamic_range). |
1524
1525**Returns**
1526
1527Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1528
1529
1530### OH_DecodingOptions_GetDesiredRegion()
1531
1532```
1533Image_ErrorCode OH_DecodingOptions_GetDesiredRegion(OH_DecodingOptions *options, Image_Region *desiredRegion)
1534```
1535
1536**Description**
1537
1538Obtains the region to decode.
1539
1540**Since**: 12
1541
1542**Parameters**
1543
1544| Name| Description|
1545| -------- | -------- |
1546| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1547| desiredRegion | Pointer to the region to decode. |
1548
1549**Returns**
1550
1551Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1552
1553
1554### OH_DecodingOptions_GetDesiredSize()
1555
1556```
1557Image_ErrorCode OH_DecodingOptions_GetDesiredSize(OH_DecodingOptions *options, Image_Size *desiredSize)
1558```
1559
1560**Description**
1561
1562Obtains the desired output size.
1563
1564**Since**: 12
1565
1566**Parameters**
1567
1568| Name| Description|
1569| -------- | -------- |
1570| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1571| desiredSize | Pointer to the desired output size. |
1572
1573**Returns**
1574
1575Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1576
1577
1578### OH_DecodingOptions_GetIndex()
1579
1580```
1581Image_ErrorCode OH_DecodingOptions_GetIndex(OH_DecodingOptions *options, uint32_t *index)
1582```
1583
1584**Description**
1585
1586Obtains the index of an image.
1587
1588**Since**: 12
1589
1590**Parameters**
1591
1592| Name| Description|
1593| -------- | -------- |
1594| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1595| index | Pointer to the index of the image to decode. |
1596
1597**Returns**
1598
1599Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1600
1601
1602### OH_DecodingOptions_GetPixelFormat()
1603
1604```
1605Image_ErrorCode OH_DecodingOptions_GetPixelFormat(OH_DecodingOptions *options, int32_t *pixelFormat)
1606```
1607
1608**Description**
1609
1610Obtains the pixel format.
1611
1612**Since**: 12
1613
1614**Parameters**
1615
1616| Name| Description|
1617| -------- | -------- |
1618| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1619| pixelFormat | Pointer to the pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format).|
1620
1621**Returns**
1622
1623Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1624
1625
1626### OH_DecodingOptions_GetRotate()
1627
1628```
1629Image_ErrorCode OH_DecodingOptions_GetRotate(OH_DecodingOptions *options, float *rotate)
1630```
1631
1632**Description**
1633
1634Obtains the rotation degree.
1635
1636**Since**: 12
1637
1638**Parameters**
1639
1640| Name| Description|
1641| -------- | -------- |
1642| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1643| rotate | Pointer to the angle to rotate, in degrees. |
1644
1645**Returns**
1646
1647Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1648
1649
1650### OH_DecodingOptions_Release()
1651
1652```
1653Image_ErrorCode OH_DecodingOptions_Release(OH_DecodingOptions *options)
1654```
1655
1656**Description**
1657
1658Releases the pointer to an **OH_DecodingOptions** struct.
1659
1660**Since**: 12
1661
1662**Parameters**
1663
1664| Name| Description|
1665| -------- | -------- |
1666| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1667
1668**Returns**
1669
1670Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1671
1672
1673
1674### OH_DecodingOptions_SetDesiredDynamicRange()
1675
1676```
1677Image_ErrorCode OH_DecodingOptions_SetDesiredDynamicRange(OH_DecodingOptions *options, int32_t desiredDynamicRange)
1678```
1679
1680**Description**
1681
1682Sets the desired dynamic range during decoding.
1683
1684**Since**: 12
1685
1686**Parameters**
1687
1688| Name| Description|
1689| -------- | -------- |
1690| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1691| desiredDynamicRange | Desired dynamic range. For details about the available options, see [IMAGE_DYNAMIC_RANGE](#image_dynamic_range). |
1692
1693**Returns**
1694
1695Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1696
1697
1698### OH_DecodingOptions_SetDesiredRegion()
1699
1700```
1701Image_ErrorCode OH_DecodingOptions_SetDesiredRegion(OH_DecodingOptions *options, Image_Region *desiredRegion)
1702```
1703
1704**Description**
1705
1706Sets the region to decode.
1707
1708**Since**: 12
1709
1710**Parameters**
1711
1712| Name| Description|
1713| -------- | -------- |
1714| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1715| desiredRegion | Pointer to the region to decode. |
1716
1717**Returns**
1718
1719Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1720
1721
1722### OH_DecodingOptions_SetDesiredSize()
1723
1724```
1725Image_ErrorCode OH_DecodingOptions_SetDesiredSize(OH_DecodingOptions *options, Image_Size *desiredSize)
1726```
1727
1728**Description**
1729
1730Sets the desired output size.
1731
1732**Since**: 12
1733
1734**Parameters**
1735
1736| Name| Description|
1737| -------- | -------- |
1738| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1739| desiredSize | Pointer to the desired output size. |
1740
1741**Returns**
1742
1743Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1744
1745
1746### OH_DecodingOptions_SetIndex()
1747
1748```
1749Image_ErrorCode OH_DecodingOptions_SetIndex(OH_DecodingOptions *options, uint32_t index)
1750```
1751
1752**Description**
1753
1754Sets the index for an image.
1755
1756**Since**: 12
1757
1758**Parameters**
1759
1760| Name| Description|
1761| -------- | -------- |
1762| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1763| index | Index of the image to decode. |
1764
1765**Returns**
1766
1767Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1768
1769
1770### OH_DecodingOptions_SetPixelFormat()
1771
1772```
1773Image_ErrorCode OH_DecodingOptions_SetPixelFormat(OH_DecodingOptions *options, int32_t pixelFormat)
1774```
1775
1776**Description**
1777
1778Sets the pixel format.
1779
1780**Since**: 12
1781
1782**Parameters**
1783
1784| Name| Description|
1785| -------- | -------- |
1786| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1787| pixelFormat | Pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format). |
1788
1789**Returns**
1790
1791Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1792
1793
1794### OH_DecodingOptions_SetRotate()
1795
1796```
1797Image_ErrorCode OH_DecodingOptions_SetRotate(OH_DecodingOptions *options, float rotate)
1798```
1799
1800**Description**
1801
1802Sets the rotation angle.
1803
1804**Since**: 12
1805
1806**Parameters**
1807
1808| Name| Description|
1809| -------- | -------- |
1810| options | Pointer to an [OH_DecodingOptions](#oh_decodingoptions) struct. |
1811| rotate | Angle to rotate, in degrees. |
1812
1813**Returns**
1814
1815Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1816
1817
1818### OH_DecodingOptionsForPicture_Create()
1819
1820```
1821Image_ErrorCode OH_DecodingOptionsForPicture_Create(OH_DecodingOptionsForPicture **options)
1822```
1823
1824**Description**
1825
1826Creates the pointer to an **OH_DecodingOptionsForPicture** struct.
1827
1828**Since**: 13
1829
1830**Parameters**
1831
1832| Name| Description|
1833| -------- | -------- |
1834| options | Double pointer to the **OH_DecodingOptionsForPicture** struct created. |
1835
1836**Returns**
1837
1838Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1839
1840
1841### OH_DecodingOptionsForPicture_GetDesiredAuxiliaryPictures()
1842
1843```
1844Image_ErrorCode OH_DecodingOptionsForPicture_GetDesiredAuxiliaryPictures(OH_DecodingOptionsForPicture *options, Image_AuxiliaryPictureType **desiredAuxiliaryPictures, size_t *length)
1845```
1846
1847**Description**
1848
1849Obtains desired auxiliary pictures in the decoding parameters (auxiliary pictures contained in **picture** expected to be decoded.)
1850
1851**Since**: 13
1852
1853**Parameters**
1854
1855| Name| Description|
1856| -------- | -------- |
1857| options | Pointer to an **OH_DecodingOptionsForPicture** struct. |
1858| desiredAuxiliaryPictures | Double pointer to the desired auxiliary pictures. |
1859| length | Pointer to the length of the desired auxiliary pictures. |
1860
1861**Returns**
1862
1863Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1864
1865
1866### OH_DecodingOptionsForPicture_Release()
1867
1868```
1869Image_ErrorCode OH_DecodingOptionsForPicture_Release(OH_DecodingOptionsForPicture *options)
1870```
1871
1872**Description**
1873
1874Releases the pointer to an **OH_DecodingOptionsForPicture** struct.
1875
1876**Since**: 13
1877
1878**Parameters**
1879
1880| Name| Description|
1881| -------- | -------- |
1882| options | Pointer to an **OH_DecodingOptionsForPicture** struct. |
1883
1884**Returns**
1885
1886Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1887
1888
1889### OH_DecodingOptionsForPicture_SetDesiredAuxiliaryPictures()
1890
1891```
1892Image_ErrorCode OH_DecodingOptionsForPicture_SetDesiredAuxiliaryPictures(OH_DecodingOptionsForPicture *options, Image_AuxiliaryPictureType *desiredAuxiliaryPictures, size_t length)
1893```
1894
1895**Description**
1896
1897Sets desired auxiliary pictures in the decoding parameters.
1898
1899**Since**: 13
1900
1901**Parameters**
1902
1903| Name| Description|
1904| -------- | -------- |
1905| options | Pointer to an **OH_DecodingOptionsForPicture** struct. |
1906| desiredAuxiliaryPictures | Pointer to the desired auxiliary pictures. |
1907| length | Length of the desired auxiliary pictures. |
1908
1909**Returns**
1910
1911Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1912
1913
1914### OH_ImageNative_GetBufferSize()
1915
1916```
1917Image_ErrorCode OH_ImageNative_GetBufferSize(OH_ImageNative *image, uint32_t componentType, size_t *size)
1918```
1919
1920**Description**
1921
1922Obtains the size of the buffer corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object.
1923
1924**Since**: 12
1925
1926**Parameters**
1927
1928| Name| Description|
1929| -------- | -------- |
1930| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
1931| componentType | Component type. |
1932| size | Pointer to the size of the buffer. |
1933
1934**Returns**
1935
1936Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1937
1938
1939### OH_ImageNative_GetByteBuffer()
1940
1941```
1942Image_ErrorCode OH_ImageNative_GetByteBuffer(OH_ImageNative *image, uint32_t componentType, OH_NativeBuffer **nativeBuffer)
1943```
1944
1945**Description**
1946
1947Obtains the buffer corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object.
1948
1949**Since**: 12
1950
1951**Parameters**
1952
1953| Name| Description|
1954| -------- | -------- |
1955| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
1956| componentType | Component type. |
1957| nativeBuffer | Double pointer to the buffer, which is an **OH_NativeBuffer** object. |
1958
1959**Returns**
1960
1961Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1962
1963
1964### OH_ImageNative_GetComponentTypes()
1965
1966```
1967Image_ErrorCode OH_ImageNative_GetComponentTypes(OH_ImageNative *image, uint32_t **types, size_t *typeSize)
1968```
1969
1970**Description**
1971
1972Obtains the component types of a native [OH_ImageNative](#oh_imagenative) object.
1973
1974**Since**: 12
1975
1976**Parameters**
1977
1978| Name| Description|
1979| -------- | -------- |
1980| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
1981| types | Double pointer to the component types obtained. |
1982| typeSize | Pointer to the number of component types obtained. |
1983
1984**Returns**
1985
1986Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
1987
1988
1989### OH_ImageNative_GetImageSize()
1990
1991```
1992Image_ErrorCode OH_ImageNative_GetImageSize(OH_ImageNative *image, Image_Size *size)
1993```
1994
1995**Description**
1996
1997Obtains the [Image_Size](_image___size.md) information of a native [OH_ImageNative](#oh_imagenative) object.
1998
1999If the [OH_ImageNative](#oh_imagenative) object stores the camera preview stream data (YUV image data), the width and height in [Image_Size](_image___size.md) obtained correspond to those of the YUV image. If the [OH_ImageNative](#oh_imagenative) object stores the camera photo stream data (JPEG image data, which is already encoded), the width in [Image_Size](_image___size.md) obtained is the JPEG data size, and the height is 1. The type of data stored in the [OH_ImageNative](#oh_imagenative) object depends on whether the application passes the surface ID in the receiver to a **previewOutput** or **captureOutput** object of the camera. For details about the best practices of camera preview and photo capture, see [Secondary Processing of Preview Streams (C/C++)](../../media/camera/native-camera-preview-imageReceiver.md) and [Photo Capture (C/C++)](../../media/camera/native-camera-shooting.md).
2000
2001**Since**: 12
2002
2003**Parameters**
2004
2005| Name| Description|
2006| -------- | -------- |
2007| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
2008| size | Pointer to the [Image_Size](_image___size.md) object obtained. |
2009
2010**Returns**
2011
2012Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2013
2014
2015### OH_ImageNative_GetPixelStride()
2016
2017```
2018Image_ErrorCode OH_ImageNative_GetPixelStride(OH_ImageNative *image, uint32_t componentType, int32_t *pixelStride)
2019```
2020
2021**Description**
2022
2023Obtains the pixel stride corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object.
2024
2025**Since**: 12
2026
2027**Parameters**
2028
2029| Name| Description|
2030| -------- | -------- |
2031| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
2032| componentType | Component type. |
2033| pixelStride | Pointer to the pixel stride obtained. |
2034
2035**Returns**
2036
2037Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2038
2039
2040### OH_ImageNative_GetRowStride()
2041
2042```
2043Image_ErrorCode OH_ImageNative_GetRowStride(OH_ImageNative *image, uint32_t componentType, int32_t *rowStride)
2044```
2045
2046**Description**
2047
2048Obtains the row stride corresponding to a component type in a native [OH_ImageNative](#oh_imagenative) object.
2049
2050Camera preview stream data must be read based on the stride. For details, see [Secondary Processing of Preview Streams (C/C++)](../../media/camera/native-camera-preview-imageReceiver.md).
2051
2052**Since**: 12
2053
2054**Parameters**
2055
2056| Name| Description|
2057| -------- | -------- |
2058| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
2059| componentType | Component type. |
2060| rowStride | Pointer to the row stride obtained. |
2061
2062**Returns**
2063
2064Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2065
2066
2067### OH_ImageNative_GetTimestamp()
2068
2069```
2070Image_ErrorCode OH_ImageNative_GetTimestamp(OH_ImageNative *image, int64_t *timestamp)
2071```
2072
2073**Description**
2074
2075Obtains the timestamp of a native [OH_ImageNative](#oh_imagenative) object.
2076
2077Timestamps, measured in nanoseconds, are usually monotonically increasing. The specific meaning and baseline of these timestamps are determined by the image producer, which is the camera in the camera preview and photo scenarios. As a result, images from different producers may carry timestamps with distinct meanings and baselines, making direct comparison between them infeasible. To obtain the generation time of a photo, you can use [OH_ImageSourceNative_GetImageProperty](#oh_imagesourcenative_getimageproperty) to read the related EXIF information.
2078
2079**Since**: 12
2080
2081**Parameters**
2082
2083| Name| Description|
2084| -------- | -------- |
2085| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
2086| timestamp | Pointer to the timestamp. |
2087
2088**Returns**
2089
2090Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2091
2092
2093### OH_ImageNative_Release()
2094
2095```
2096Image_ErrorCode OH_ImageNative_Release(OH_ImageNative *image)
2097```
2098
2099**Description**
2100
2101Releases a native [OH_ImageNative](#oh_imagenative) object.
2102
2103**Since**: 12
2104
2105**Parameters**
2106
2107| Name| Description|
2108| -------- | -------- |
2109| image | Pointer to a native [OH_ImageNative](#oh_imagenative) object. |
2110
2111**Returns**
2112
2113Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2114
2115
2116### OH_ImagePackerNative_Create()
2117
2118```
2119Image_ErrorCode OH_ImagePackerNative_Create(OH_ImagePackerNative **imagePacker)
2120```
2121
2122**Description**
2123
2124Creates the pointer to an **OH_ImagePackerNative** object.
2125
2126**Since**: 12
2127
2128**Parameters**
2129
2130| Name| Description|
2131| -------- | -------- |
2132| options | Double pointer to the **OH_ImagePackerNative** object created. |
2133
2134**Returns**
2135
2136Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2137
2138
2139### OH_ImagePackerNative_PackToDataFromImageSource()
2140
2141```
2142Image_ErrorCode OH_ImagePackerNative_PackToDataFromImageSource(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_ImageSourceNative *imageSource, uint8_t *outData, size_t *size)
2143```
2144
2145**Description**
2146
2147Encodes an image source into data in a given format.
2148
2149**Since**: 12
2150
2151**Parameters**
2152
2153| Name| Description|
2154| -------- | -------- |
2155| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2156| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2157| imageSource | Pointer to the image source to encode. |
2158| outData | Pointer to the buffer used to store the output data. |
2159| size | Pointer to the size of the buffer. |
2160
2161**Returns**
2162
2163Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if image decoding fails; returns **IMAGE_ALLOC_FAILED** if memory allocation fails; returns **IMAGE_TOO_LARGE** if the data or image is too large; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2164
2165
2166### OH_ImagePackerNative_PackToDataFromPicture()
2167
2168```
2169Image_ErrorCode OH_ImagePackerNative_PackToDataFromPicture(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_PictureNative *picture, uint8_t *outData, size_t *size)
2170```
2171
2172**Description**
2173
2174Encodes a picture into data in a given format.
2175
2176**Since**: 13
2177
2178**Parameters**
2179
2180| Name| Description|
2181| -------- | -------- |
2182| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2183| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2184| picture | Pointer to the picture to encode. |
2185| outData | Pointer to the buffer used to store the output data. |
2186| size | Pointer to the size of the buffer. |
2187
2188**Returns**
2189
2190Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if decoding fails. For details, see [Image_ErrorCode](#image_errorcode).
2191
2192
2193### OH_ImagePackerNative_PackToDataFromPixelmap()
2194
2195```
2196Image_ErrorCode OH_ImagePackerNative_PackToDataFromPixelmap(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_PixelmapNative *pixelmap, uint8_t *outData, size_t *size)
2197```
2198
2199**Description**
2200
2201Encodes a PixelMap into data in a given format.
2202
2203**Since**: 12
2204
2205**Parameters**
2206
2207| Name| Description|
2208| -------- | -------- |
2209| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2210| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2211| pixelmap | Pointer to the PixelMap to encode. |
2212| outData | Pointer to the buffer used to store the output data. |
2213| size | Pointer to the size of the buffer. |
2214
2215**Returns**
2216
2217Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if image decoding fails; returns **IMAGE_ALLOC_FAILED** if memory allocation fails; returns **IMAGE_TOO_LARGE** if the data or image is too large; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2218
2219
2220### OH_ImagePackerNative_PackToDataFromPixelmapSequence()
2221
2222```
2223Image_ErrorCode OH_ImagePackerNative_PackToDataFromPixelmapSequence(OH_ImagePackerNative *imagePacker, OH_PackingOptionsForSequence *options, OH_PixelmapNative **pixelmapSequence, size_t sequenceLength, uint8_t *outData, size_t *outDataSize)
2224```
2225
2226**Description**
2227
2228Encodes a PixelMap sequence into data.
2229
2230**Since**: 13
2231
2232**Parameters**
2233
2234| Name| Description|
2235| -------- | -------- |
2236| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2237| options | Pointer to an [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) struct. |
2238| pixelmapSequence | Double pointer to the PixelMap sequence to encode. |
2239| sequenceLength | Length of the PixelMap sequence. |
2240| outData | Pointer to the buffer used to store the output data. |
2241| outDataSize | Pointer to the size of the buffer. |
2242
2243**Returns**
2244
2245Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if decoding fails. For details, see [Image_ErrorCode](#image_errorcode).
2246
2247
2248### OH_ImagePackerNative_PackToFileFromImageSource()
2249
2250```
2251Image_ErrorCode OH_ImagePackerNative_PackToFileFromImageSource(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_ImageSourceNative *imageSource, int32_t fd)
2252```
2253
2254**Description**
2255
2256Encodes an image source into a file.
2257
2258**Since**: 12
2259
2260**Parameters**
2261
2262| Name| Description|
2263| -------- | -------- |
2264| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2265| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2266| imageSource | Pointer to the image source to encode. |
2267| fd | File descriptor, which is writable. |
2268
2269**Returns**
2270
2271Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if image decoding fails; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2272
2273
2274### OH_ImagePackerNative_PackToFileFromPicture()
2275
2276```
2277Image_ErrorCode OH_ImagePackerNative_PackToFileFromPicture(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_PictureNative *picture, int32_t fd)
2278```
2279
2280**Description**
2281
2282Encodes a picture into a file.
2283
2284**Since**: 13
2285
2286**Parameters**
2287
2288| Name| Description|
2289| -------- | -------- |
2290| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2291| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2292| picture | Pointer to the picture to encode. |
2293| fd | File descriptor, which is writable. |
2294
2295**Returns**
2296
2297Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if image decoding fails; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2298
2299
2300### OH_ImagePackerNative_PackToFileFromPixelmap()
2301
2302```
2303Image_ErrorCode OH_ImagePackerNative_PackToFileFromPixelmap(OH_ImagePackerNative *imagePacker, OH_PackingOptions *options, OH_PixelmapNative *pixelmap, int32_t fd)
2304```
2305
2306**Description**
2307
2308Encodes a PixelMap into a file.
2309
2310**Since**: 12
2311
2312**Parameters**
2313
2314| Name| Description|
2315| -------- | -------- |
2316| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2317| options | Pointer to an [OH_PackingOptions](#oh_packingoptions) struct. |
2318| pixelmap | Pointer to the PixelMap to encode. |
2319| fd | File descriptor, which is writable. |
2320
2321**Returns**
2322
2323Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if image decoding fails; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2324
2325
2326### OH_ImagePackerNative_PackToFileFromPixelmapSequence()
2327
2328```
2329Image_ErrorCode OH_ImagePackerNative_PackToFileFromPixelmapSequence(OH_ImagePackerNative *imagePacker, OH_PackingOptionsForSequence *options, OH_PixelmapNative **pixelmapSequence, size_t sequenceLength, int32_t fd)
2330```
2331
2332**Description**
2333
2334Encodes a PixelMap sequence into a file.
2335
2336**Since**: 13
2337
2338**Parameters**
2339
2340| Name| Description|
2341| -------- | -------- |
2342| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2343| options | Pointer to an [OH_PackingOptionsForSequence](#oh_packingoptionsforsequence) struct. |
2344| pixelmapSequence | Double pointer to the PixelMap sequence to encode. |
2345| sequenceLength | Length of the PixelMap sequence. |
2346| fd | File descriptor, which is writable. |
2347
2348**Returns**
2349
2350Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if decoding fails. For details, see [Image_ErrorCode](#image_errorcode).
2351
2352
2353### OH_ImagePackerNative_Release()
2354
2355```
2356Image_ErrorCode OH_ImagePackerNative_Release(OH_ImagePackerNative *imagePacker)
2357```
2358
2359**Description**
2360
2361Releases the pointer to an **OH_ImagePackerNative** object.
2362
2363**Since**: 12
2364
2365**Parameters**
2366
2367| Name| Description|
2368| -------- | -------- |
2369| imagePacker | Pointer to an **OH_ImagePackerNative** object. |
2370
2371**Returns**
2372
2373Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2374
2375
2376### OH_ImageReceiverNative_Create()
2377
2378```
2379Image_ErrorCode OH_ImageReceiverNative_Create(OH_ImageReceiverOptions* options, OH_ImageReceiverNative** receiver)
2380```
2381
2382**Description**
2383
2384Creates an **OH_ImageReceiverNative** object at the application layer.
2385
2386**Since**: 12
2387
2388**Parameters**
2389
2390| Name| Description|
2391| -------- | -------- |
2392| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2393| receiver | Double pointer to the [OH_ImageReceiverNative](#oh_imagereceivernative) object created. |
2394
2395**Returns**
2396
2397Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_ALLOC_FAILED** if memory allocation fails. For details, see [Image_ErrorCode](#image_errorcode).
2398
2399
2400### OH_ImageReceiverNative_GetCapacity()
2401
2402```
2403Image_ErrorCode OH_ImageReceiverNative_GetCapacity(OH_ImageReceiverNative* receiver, int32_t* capacity)
2404```
2405
2406**Description**
2407
2408Obtains the capacity of an image receiver, which is an [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2409
2410**Since**: 12
2411
2412**Parameters**
2413
2414| Name| Description|
2415| -------- | -------- |
2416| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2417| capacity | Pointer to the capacity obtained. |
2418
2419**Returns**
2420
2421Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2422
2423**See**
2424
2425[OH_ImageReceiverNative](#oh_imagereceivernative)
2426
2427
2428### OH_ImageReceiverNative_GetReceivingSurfaceId()
2429
2430```
2431Image_ErrorCode OH_ImageReceiverNative_GetReceivingSurfaceId(OH_ImageReceiverNative* receiver, uint64_t* surfaceId)
2432```
2433
2434**Description**
2435
2436Obtains the receiver ID through an [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2437
2438**Since**: 12
2439
2440**Parameters**
2441
2442| Name| Description|
2443| -------- | -------- |
2444| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2445| surfaceId | Pointer to the surface ID obtained. |
2446
2447**Returns**
2448
2449Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
2450
2451**See**
2452
2453[OH_ImageReceiverNative](#oh_imagereceivernative)
2454
2455
2456### OH_ImageReceiverNative_GetSize()
2457
2458```
2459Image_ErrorCode OH_ImageReceiverNative_GetSize(OH_ImageReceiverNative* receiver, Image_Size* size)
2460```
2461
2462**Description**
2463
2464Obtains the size of an image receiver, which is an [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2465
2466**Since**: 12
2467
2468**Parameters**
2469
2470| Name| Description|
2471| -------- | -------- |
2472| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2473| size | Pointer to the [Image_Size](_image___size.md) object obtained. |
2474
2475**Returns**
2476
2477Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2478
2479**See**
2480
2481[OH_ImageReceiverNative](#oh_imagereceivernative), [Image_Size](_image___size.md)
2482
2483
2484### OH_ImageReceiverNative_Off()
2485
2486```
2487Image_ErrorCode OH_ImageReceiverNative_Off(OH_ImageReceiverNative* receiver)
2488```
2489
2490**Description**
2491
2492Unregisters the callback defined in [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback).
2493
2494The callback is registered by calling [OH_ImageReceiverNative_On](#oh_imagereceivernative_on).
2495
2496**Since**: 12
2497
2498**Parameters**
2499
2500| Name| Description|
2501| -------- | -------- |
2502| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2503
2504**Returns**
2505
2506Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2507
2508**See**
2509
2510[OH_ImageReceiverNative](#oh_imagereceivernative), [OH_ImageReceiverNative_On](#oh_imagereceivernative_on)
2511
2512
2513### OH_ImageReceiverNative_On()
2514
2515```
2516Image_ErrorCode OH_ImageReceiverNative_On(OH_ImageReceiverNative* receiver, OH_ImageReceiver_OnCallback callback)
2517```
2518
2519**Description**
2520
2521Registers the callback defined in [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback).
2522
2523This callback is triggered whenever a new image is received.
2524
2525**Since**: 12
2526
2527**Parameters**
2528
2529| Name| Description|
2530| -------- | -------- |
2531| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2532| callback | Callback defined in [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback). |
2533
2534**Returns**
2535
2536Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2537
2538**See**
2539
2540[OH_ImageReceiverNative](#oh_imagereceivernative), [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback)
2541
2542
2543### OH_ImageReceiverNative_ReadLatestImage()
2544
2545```
2546Image_ErrorCode OH_ImageReceiverNative_ReadLatestImage(OH_ImageReceiverNative* receiver, OH_ImageNative** image)
2547```
2548
2549**Description**
2550
2551Obtains the latest image through an [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2552
2553> **NOTE**
2554>
2555> This function can be called to receive data only after the [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback) callback is triggered. When the [OH_ImageNative](#oh_imagenative) object returned by this function is no longer needed, call [OH_ImageNative_Release](#oh_imagenative_release) to release the object. New data can be received only after the release.
2556
2557**Since**: 12
2558
2559**Parameters**
2560
2561| Name| Description|
2562| -------- | -------- |
2563| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2564| image | Double pointer to the image obtained, which is an **OH_ImageNative** object at the application layer. |
2565
2566**Returns**
2567
2568Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs; returns **IMAGE_ALLOC_FAILED** if memory allocation fails. For details, see [Image_ErrorCode](#image_errorcode).
2569
2570**See**
2571
2572[OH_ImageReceiverNative](#oh_imagereceivernative), [OH_ImageNative](#oh_imagenative)
2573
2574
2575### OH_ImageReceiverNative_ReadNextImage()
2576
2577```
2578Image_ErrorCode OH_ImageReceiverNative_ReadNextImage(OH_ImageReceiverNative* receiver, OH_ImageNative** image)
2579```
2580
2581**Description**
2582
2583Obtains the next image through an [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2584
2585> **NOTE**
2586>
2587> This function can be called to receive data only after the [OH_ImageReceiver_OnCallback](#oh_imagereceiver_oncallback) callback is triggered. When the [OH_ImageNative](#oh_imagenative) object returned by this function is no longer needed, call [OH_ImageNative_Release](#oh_imagenative_release) to release the object. New data can be received only after the release.
2588
2589**Since**: 12
2590
2591**Parameters**
2592
2593| Name| Description|
2594| -------- | -------- |
2595| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2596| image | Double pointer to the image obtained, which is an **OH_ImageNative** object at the application layer. |
2597
2598**Returns**
2599
2600Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs; returns **IMAGE_ALLOC_FAILED** if memory allocation fails. For details, see [Image_ErrorCode](#image_errorcode).
2601
2602**See**
2603
2604[OH_ImageReceiverNative](#oh_imagereceivernative), [OH_ImageNative](#oh_imagenative)
2605
2606
2607### OH_ImageReceiverNative_Release()
2608
2609```
2610Image_ErrorCode OH_ImageReceiverNative_Release(OH_ImageReceiverNative* receiver)
2611```
2612
2613**Description**
2614
2615Releases a native [OH_ImageReceiverNative](#oh_imagereceivernative) object.
2616
2617**Since**: 12
2618
2619**Parameters**
2620
2621| Name| Description|
2622| -------- | -------- |
2623| receiver | Pointer to an [OH_ImageReceiverNative](#oh_imagereceivernative) object. |
2624
2625**Returns**
2626
2627Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2628
2629**See**
2630
2631[OH_ImageReceiverNative](#oh_imagereceivernative)
2632
2633
2634### OH_ImageReceiverOptions_Create()
2635
2636```
2637Image_ErrorCode OH_ImageReceiverOptions_Create(OH_ImageReceiverOptions **options)
2638```
2639
2640**Description**
2641
2642Creates an **OH_ImageReceiverOptions** object at the application layer.
2643
2644**Since**: 12
2645
2646**Parameters**
2647
2648| Name| Description|
2649| -------- | -------- |
2650| options | Double pointer to the [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object created. |
2651
2652**Returns**
2653
2654Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_ALLOC_FAILED** if memory allocation fails. For details, see [Image_ErrorCode](#image_errorcode).
2655
2656
2657### OH_ImageReceiverOptions_GetCapacity()
2658
2659```
2660Image_ErrorCode OH_ImageReceiverOptions_GetCapacity(OH_ImageReceiverOptions* options, int32_t* capacity)
2661```
2662
2663**Description**
2664
2665Obtains the capacity of an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object.
2666
2667**Since**: 12
2668
2669**Parameters**
2670
2671| Name| Description|
2672| -------- | -------- |
2673| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2674| capacity | Pointer to the capacity obtained. |
2675
2676**Returns**
2677
2678Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2679
2680
2681### OH_ImageReceiverOptions_GetSize()
2682
2683```
2684Image_ErrorCode OH_ImageReceiverOptions_GetSize(OH_ImageReceiverOptions* options, Image_Size* size)
2685```
2686
2687**Description**
2688
2689Obtains the [Image_Size](_image___size.md) information of an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object.
2690
2691**Since**: 12
2692
2693**Parameters**
2694
2695| Name| Description|
2696| -------- | -------- |
2697| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2698| size | Pointer to the [Image_Size](_image___size.md) object obtained. |
2699
2700**Returns**
2701
2702Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2703
2704
2705### OH_ImageReceiverOptions_Release()
2706
2707```
2708Image_ErrorCode OH_ImageReceiverOptions_Release(OH_ImageReceiverOptions* options)
2709```
2710
2711**Description**
2712
2713Releases an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object.
2714
2715**Since**: 12
2716
2717**Parameters**
2718
2719| Name| Description|
2720| -------- | -------- |
2721| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2722
2723**Returns**
2724
2725Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2726
2727**See**
2728
2729[OH_ImageReceiverOptions](#oh_imagereceiveroptions)
2730
2731
2732### OH_ImageReceiverOptions_SetCapacity()
2733
2734```
2735Image_ErrorCode OH_ImageReceiverOptions_SetCapacity(OH_ImageReceiverOptions* options, int32_t capacity)
2736```
2737
2738**Description**
2739
2740Sets the capacity for an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object.
2741
2742**Since**: 12
2743
2744**Parameters**
2745
2746| Name| Description|
2747| -------- | -------- |
2748| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2749| capacity | Capacity to set. |
2750
2751**Returns**
2752
2753Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2754
2755
2756### OH_ImageReceiverOptions_SetSize()
2757
2758```
2759Image_ErrorCode OH_ImageReceiverOptions_SetSize(OH_ImageReceiverOptions* options, Image_Size size)
2760```
2761
2762**Description**
2763
2764Sets the [Image_Size](_image___size.md) information for an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object.
2765
2766**Since**: 12
2767
2768**Parameters**
2769
2770| Name| Description|
2771| -------- | -------- |
2772| options | Pointer to an [OH_ImageReceiverOptions](#oh_imagereceiveroptions) object. |
2773| size | [Image_Size](_image___size.md) object. |
2774
2775**Returns**
2776
2777Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2778
2779
2780### OH_ImageSourceInfo_Create()
2781
2782```
2783Image_ErrorCode OH_ImageSourceInfo_Create(OH_ImageSource_Info **info)
2784```
2785
2786**Description**
2787
2788Creates the pointer to an **OH_ImageSource_Info** struct.
2789
2790**Since**: 12
2791
2792**Parameters**
2793
2794| Name| Description|
2795| -------- | -------- |
2796| info | Double pointer to the **OH_ImageSource_Info** struct created. |
2797
2798**Returns**
2799
2800Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2801
2802
2803### OH_ImageSourceInfo_GetDynamicRange()
2804
2805```
2806Image_ErrorCode OH_ImageSourceInfo_GetDynamicRange(OH_ImageSource_Info *info, bool *isHdr)
2807```
2808
2809**Description**
2810
2811Obtains the dynamic range of an image.
2812
2813**Since**: 12
2814
2815**Parameters**
2816
2817| Name| Description|
2818| -------- | -------- |
2819| info | Pointer to an **OH_ImageSource_Info** struct. |
2820| isHdr | Pointer to a Boolean that specifies whether the HDR is used. |
2821
2822**Returns**
2823
2824Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2825
2826
2827### OH_ImageSourceInfo_GetHeight()
2828
2829```
2830Image_ErrorCode OH_ImageSourceInfo_GetHeight(OH_ImageSource_Info *info, uint32_t *height)
2831```
2832
2833**Description**
2834
2835Obtains the image height.
2836
2837**Since**: 12
2838
2839**Parameters**
2840
2841| Name| Description|
2842| -------- | -------- |
2843| info | Pointer to an **OH_ImageSource_Info** struct. |
2844| height | Pointer to the image height, in px. |
2845
2846**Returns**
2847
2848Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2849
2850
2851### OH_ImageSourceInfo_GetWidth()
2852
2853```
2854Image_ErrorCode OH_ImageSourceInfo_GetWidth(OH_ImageSource_Info *info, uint32_t *width)
2855```
2856
2857**Description**
2858
2859Obtains the image width.
2860
2861**Since**: 12
2862
2863**Parameters**
2864
2865| Name| Description|
2866| -------- | -------- |
2867| info | Pointer to an **OH_ImageSource_Info** struct. |
2868| width | Pointer to the image width, in px. |
2869
2870**Returns**
2871
2872Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2873
2874
2875### OH_ImageSourceInfo_Release()
2876
2877```
2878Image_ErrorCode OH_ImageSourceInfo_Release(OH_ImageSource_Info *info)
2879```
2880
2881**Description**
2882
2883Releases the pointer to an **OH_ImageSource_Info** struct.
2884
2885**Since**: 12
2886
2887**Parameters**
2888
2889| Name| Description|
2890| -------- | -------- |
2891| info | Pointer to an **OH_ImageSource_Info** struct. |
2892
2893**Returns**
2894
2895Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2896
2897
2898### OH_ImageSourceNative_CreateFromData()
2899
2900```
2901Image_ErrorCode OH_ImageSourceNative_CreateFromData(uint8_t *data, size_t dataSize, OH_ImageSourceNative **res)
2902```
2903
2904**Description**
2905
2906Creates the pointer to an **OH_ImageSourceNative** object based on buffer data.
2907
2908The buffer data must be undecoded. Do not pass the pixel buffer data such as RBGA and YUV. If you want to create a PixelMap based on the pixel buffer data, call [OH_PixelmapNative_CreatePixelmap](./pixelmap__native_8h.md).
2909
2910**Since**: 12
2911
2912**Parameters**
2913
2914| Name| Description|
2915| -------- | -------- |
2916| data | Pointer to the buffer data. |
2917| dataSize | Size of the buffer. |
2918| res | Double pointer to the **OH_ImageSourceNative** object created at the C++ local layer. |
2919
2920**Returns**
2921
2922Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_BAD_SOURCE** if the data source is abnormal. For details, see [Image_ErrorCode](#image_errorcode).
2923
2924
2925### OH_ImageSourceNative_CreateFromFd()
2926
2927```
2928Image_ErrorCode OH_ImageSourceNative_CreateFromFd(int32_t fd, OH_ImageSourceNative **res)
2929```
2930
2931**Description**
2932
2933Creates the pointer to an **OH_ImageSourceNative** object based on a file descriptor.
2934
2935**Since**: 12
2936
2937**Parameters**
2938
2939| Name| Description|
2940| -------- | -------- |
2941| fd | File descriptor. |
2942| res | Double pointer to the **OH_ImageSourceNative** object created at the C++ local layer. |
2943
2944**Returns**
2945
2946Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2947
2948
2949### OH_ImageSourceNative_CreateFromRawFile()
2950
2951```
2952Image_ErrorCode OH_ImageSourceNative_CreateFromRawFile(RawFileDescriptor *rawFile, OH_ImageSourceNative **res)
2953```
2954
2955**Description**
2956
2957Creates the pointer to an **OH_ImageSourceNative** object by using the raw file descriptor of an image resource file.
2958
2959**Since**: 12
2960
2961**Parameters**
2962
2963| Name| Description|
2964| -------- | -------- |
2965| rawFile | Pointer to the file descriptor of the raw file. |
2966| res | Double pointer to the **OH_ImageSourceNative** object created at the C++ local layer. |
2967
2968**Returns**
2969
2970Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
2971
2972
2973### OH_ImageSourceNative_CreateFromUri()
2974
2975```
2976Image_ErrorCode OH_ImageSourceNative_CreateFromUri(char *uri, size_t uriSize, OH_ImageSourceNative **res)
2977```
2978
2979**Description**
2980
2981Creates the pointer to an **OH_ImageSourceNative** object based on a URI.
2982
2983**Since**: 12
2984
2985**Parameters**
2986
2987| Name| Description|
2988| -------- | -------- |
2989| uri | Pointer to the URI of the image source. Only file URIs or Base64 URIs are accepted. Currently, only absolute paths are supported. |
2990| uriSize | URI length. |
2991| res | Double pointer to the **OH_ImageSourceNative** object created at the C++ local layer. |
2992
2993**Returns**
2994
2995Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_BAD_SOURCE** if the data source is abnormal. For details, see [Image_ErrorCode](#image_errorcode).
2996
2997
2998### OH_ImageSourceNative_CreatePicture()
2999
3000```
3001Image_ErrorCode OH_ImageSourceNative_CreatePicture(OH_ImageSourceNative *source, OH_DecodingOptionsForPicture *options, OH_PictureNative **picture)
3002```
3003
3004**Description**
3005
3006Creates the pointer to an **OH_PictureNative** object based on image decoding parameters.
3007
3008**Since**: 13
3009
3010**Parameters**
3011
3012| Name| Description|
3013| -------- | -------- |
3014| source | Pointer to an **OH_ImageSourceNative** object. |
3015| options | Pointer to the image decoding parameters. |
3016| picture | Double pointer to the **OH_PictureNative** object created at the C++ local layer. |
3017
3018**Returns**
3019
3020Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DECODE_FAILED** if decoding fails. For details, see [Image_ErrorCode](#image_errorcode).
3021
3022
3023### OH_ImageSourceNative_CreatePixelmap()
3024
3025```
3026Image_ErrorCode OH_ImageSourceNative_CreatePixelmap(OH_ImageSourceNative *source, OH_DecodingOptions *options, OH_PixelmapNative **pixelmap)
3027```
3028
3029**Description**
3030
3031Creates the pointer to an **OH_PixelmapNative** object based on image decoding parameters.
3032
3033**Since**: 12
3034
3035**Parameters**
3036
3037| Name| Description|
3038| -------- | -------- |
3039| source | Pointer to an **OH_ImageSourceNative** object. |
3040| options | Pointer to the image decoding parameters. |
3041| resPixMap | Double pointer to the **OH_PixelmapNative** object created at the C++ local layer. |
3042
3043**Returns**
3044
3045Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3046
3047
3048### OH_ImageSourceNative_CreatePixelmapList()
3049
3050```
3051Image_ErrorCode OH_ImageSourceNative_CreatePixelmapList(OH_ImageSourceNative *source, OH_DecodingOptions *options, OH_PixelmapNative *resVecPixMap[], size_t size)
3052```
3053
3054**Description**
3055
3056Creates an array of **OH_PixelmapNative** objects based on image decoding parameters.
3057
3058**Since**: 12
3059
3060**Parameters**
3061
3062| Name| Description|
3063| -------- | -------- |
3064| source | Pointer to an **OH_ImageSourceNative** object. |
3065| options | Pointer to the image decoding parameters. |
3066| resVecPixMap | Pointer to an array of **OH_PixelmapNative** objects created at the C++ local layer. |
3067| size | Size of the array. You can use [OH_ImageSourceNative_GetFrameCount](#oh_imagesourcenative_getframecount) to obtain the size. |
3068
3069**Returns**
3070
3071Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_OPERATION** if the operation is not supported. For details, see [Image_ErrorCode](#image_errorcode).
3072
3073
3074### OH_ImageSourceNative_GetDelayTimeList()
3075
3076```
3077Image_ErrorCode OH_ImageSourceNative_GetDelayTimeList(OH_ImageSourceNative *source, int32_t *delayTimeList, size_t size)
3078```
3079
3080**Description**
3081
3082Obtains the image delay time list.
3083
3084**Since**: 12
3085
3086**Parameters**
3087
3088| Name| Description|
3089| -------- | -------- |
3090| source | Pointer to an **OH_ImageSourceNative** object. |
3091| delayTimeList | Pointer to the delay time list obtained. It cannot be a null pointer. |
3092| size | Size of the delay time list. You can use [OH_ImageSourceNative_GetFrameCount](#oh_imagesourcenative_getframecount) to obtain the size. |
3093
3094**Returns**
3095
3096Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3097
3098
3099### OH_ImageSourceNative_GetFrameCount()
3100
3101```
3102Image_ErrorCode OH_ImageSourceNative_GetFrameCount(OH_ImageSourceNative *source, uint32_t *frameCount)
3103```
3104
3105**Description**
3106
3107Obtains the number of image frames.
3108
3109**Since**: 12
3110
3111**Parameters**
3112
3113| Name| Description|
3114| -------- | -------- |
3115| source | Pointer to an **OH_ImageSourceNative** object. |
3116| frameCount | Pointer to the number of frames obtained. |
3117
3118**Returns**
3119
3120Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3121
3122
3123### OH_ImageSourceNative_GetImageInfo()
3124
3125```
3126Image_ErrorCode OH_ImageSourceNative_GetImageInfo(OH_ImageSourceNative *source, int32_t index, OH_ImageSource_Info *info)
3127```
3128
3129**Description**
3130
3131Obtains the information about an image with a given index.
3132
3133**Since**: 12
3134
3135**Parameters**
3136
3137| Name| Description|
3138| -------- | -------- |
3139| source | Pointer to an **OH_ImageSourceNative** object. |
3140| index | Index of an image. For a GIF image, the value range is [0, N-1], where N indicates the number of GIF frames. For an image with only one frame, you can pass in **0**. |
3141| info | Pointer to the image information obtained, which is an **OH_ImageSource_Info** struct. |
3142
3143**Returns**
3144
3145Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3146
3147
3148### OH_ImageSourceNative_GetImageProperty()
3149
3150```
3151Image_ErrorCode OH_ImageSourceNative_GetImageProperty(OH_ImageSourceNative *source, Image_String *key, Image_String *value)
3152```
3153
3154**Description**
3155
3156Obtains the value of an image property.
3157
3158**Since**: 12
3159
3160**Parameters**
3161
3162| Name| Description|
3163| -------- | -------- |
3164| source | Pointer to an **OH_ImageSourceNative** object. |
3165| key | Pointer to the property key. For details, see [Image_String](_image___string.md). For details about the value range of **key**, see the definition of **OHOS_IMAGE_PROPERTY_XXX**. The memory must be released after the image source is used. For details, see [OH_ImageSourceNative_Release](#oh_imagesourcenative_release). |
3166| value | Pointer to the value obtained. You can pass in a null pointer with the size set to zero. In this case, the system will allocate memory, but you must release the memory after use. |
3167
3168**Returns**
3169
3170Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3171
3172
3173### OH_ImageSourceNative_ModifyImageProperty()
3174
3175```
3176Image_ErrorCode OH_ImageSourceNative_ModifyImageProperty(OH_ImageSourceNative *source, Image_String *key, Image_String *value)
3177```
3178
3179**Description**
3180
3181Modifies the value of an image property.
3182
3183**Since**: 12
3184
3185**Parameters**
3186
3187| Name| Description|
3188| -------- | -------- |
3189| source | Pointer to an **OH_ImageSourceNative** object. |
3190| key | Pointer to the property key. For details, see [Image_String](_image___string.md). **key** is an EXIF constant. The memory must be released after the image source is used. For details, see [OH_ImageSourceNative_Release](#oh_imagesourcenative_release). |
3191| value | Pointer to the new value. |
3192
3193**Returns**
3194
3195Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3196
3197
3198### OH_ImageSourceNative_Release()
3199
3200```
3201Image_ErrorCode OH_ImageSourceNative_Release(OH_ImageSourceNative *source)
3202```
3203
3204**Description**
3205
3206Releases the pointer to an **OH_ImageSourceNative** object.
3207
3208**Since**: 12
3209
3210**Parameters**
3211
3212| Name| Description|
3213| -------- | -------- |
3214| source | Pointer to an **OH_ImageSourceNative** object. |
3215
3216**Returns**
3217
3218Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3219
3220
3221### OH_PackingOptions_Create()
3222
3223```
3224Image_ErrorCode OH_PackingOptions_Create(OH_PackingOptions **options)
3225```
3226
3227**Description**
3228
3229Creates the pointer to an **OH_PackingOptions** struct.
3230
3231**Since**: 12
3232
3233**Parameters**
3234
3235| Name| Description|
3236| -------- | -------- |
3237| options | Double pointer to the **OH_PackingOptions** struct created. |
3238
3239**Returns**
3240
3241Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3242
3243
3244### OH_PackingOptions_GetDesiredDynamicRange()
3245
3246```
3247Image_ErrorCode OH_PackingOptions_GetDesiredDynamicRange(OH_PackingOptions *options, int32_t* desiredDynamicRange)
3248```
3249
3250**Description**
3251
3252Obtains the desired dynamic range during encoding.
3253
3254**Since**: 12
3255
3256**Parameters**
3257
3258| Name| Description|
3259| -------- | -------- |
3260| options | Pointer to an **OH_PackingOptions** struct. |
3261| desiredDynamicRange | Pointer to the desired dynamic range. For details about the available options, see [IMAGE_PACKER_DYNAMIC_RANGE](#image_packer_dynamic_range). |
3262
3263**Returns**
3264
3265Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3266
3267
3268### OH_PackingOptions_GetMimeType()
3269
3270```
3271Image_ErrorCode OH_PackingOptions_GetMimeType (OH_PackingOptions * options, Image_MimeType * format )
3272```
3273
3274**Description**
3275
3276Obtains the MIME type.
3277
3278**Since**: 12
3279
3280**Parameters**
3281
3282| Name| Description|
3283| -------- | -------- |
3284| options | Pointer to an **OH_PackingOptions** struct. |
3285| format | Pointer to the image format. You can pass in a null pointer with the size set to zero. In this case, the system will allocate memory, but you must release the memory after use. |
3286
3287**Returns**
3288
3289Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3290
3291
3292### OH_PackingOptions_GetQuality()
3293
3294```
3295Image_ErrorCode OH_PackingOptions_GetQuality(OH_PackingOptions *options, uint32_t *quality)
3296```
3297
3298**Description**
3299
3300Obtains the encoding quality.
3301
3302**Since**: 12
3303
3304**Parameters**
3305
3306| Name| Description|
3307| -------- | -------- |
3308| options | Pointer to an **OH_PackingOptions** struct. |
3309| quality | Pointer to the encoding quality. |
3310
3311**Returns**
3312
3313Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3314
3315
3316### OH_PackingOptions_Release()
3317
3318```
3319Image_ErrorCode OH_PackingOptions_Release(OH_PackingOptions *options)
3320```
3321
3322**Description**
3323
3324Releases the pointer to an **OH_PackingOptions** struct.
3325
3326**Since**: 12
3327
3328**Parameters**
3329
3330| Name| Description|
3331| -------- | -------- |
3332| options | Pointer to an **OH_PackingOptions** struct. |
3333
3334**Returns**
3335
3336Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3337
3338
3339### OH_PackingOptions_SetDesiredDynamicRange()
3340
3341```
3342Image_ErrorCode OH_PackingOptions_SetDesiredDynamicRange(OH_PackingOptions *options, int32_t desiredDynamicRange)
3343```
3344
3345**Description**
3346
3347Sets the desired dynamic range during encoding.
3348
3349**Since**: 12
3350
3351**Parameters**
3352
3353| Name| Description|
3354| -------- | -------- |
3355| options | Pointer to an **OH_PackingOptions** struct. |
3356| desiredDynamicRange | Desired dynamic range. For details about the available options, see [IMAGE_PACKER_DYNAMIC_RANGE](#image_packer_dynamic_range). |
3357
3358**Returns**
3359
3360Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3361
3362
3363### OH_PackingOptions_SetMimeType()
3364
3365```
3366Image_ErrorCode OH_PackingOptions_SetMimeType(OH_PackingOptions *options, Image_MimeType *format)
3367```
3368
3369**Description**
3370
3371Sets the MIME type.
3372
3373**Since**: 12
3374
3375**Parameters**
3376
3377| Name| Description|
3378| -------- | -------- |
3379| options | Pointer to an **OH_PackingOptions** struct. |
3380| format | Pointer to the image format. |
3381
3382**Returns**
3383
3384Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3385
3386
3387### OH_PackingOptions_SetQuality()
3388
3389```
3390Image_ErrorCode OH_PackingOptions_SetQuality(OH_PackingOptions *options, uint32_t quality)
3391```
3392
3393**Description**
3394
3395Sets the encoding quality.
3396
3397**Since**: 12
3398
3399**Parameters**
3400
3401| Name| Description|
3402| -------- | -------- |
3403| options | Pointer to an **OH_PackingOptions** struct. |
3404| quality | Encoding quality. |
3405
3406**Returns**
3407
3408Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3409
3410
3411### OH_PackingOptionsForSequence_Create()
3412
3413```
3414Image_ErrorCode OH_PackingOptionsForSequence_Create(OH_PackingOptionsForSequence **options)
3415```
3416
3417**Description**
3418
3419Creates the pointer to an **OH_PackingOptionsForSequence** struct.
3420
3421**Since**: 13
3422
3423**Parameters**
3424
3425| Name| Description|
3426| -------- | -------- |
3427| options | Double pointer to the **OH_PackingOptionsForSequence** struct created. |
3428
3429**Returns**
3430
3431Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3432
3433
3434### OH_PackingOptionsForSequence_GetDelayTimeList()
3435
3436```
3437Image_ErrorCode OH_PackingOptionsForSequence_GetDelayTimeList(OH_PackingOptionsForSequence *options, int32_t *delayTimeList, size_t delayTimeListLength)
3438```
3439
3440**Description**
3441
3442Obtains the delay time array for image sequence encoding.
3443
3444**Since**: 13
3445
3446**Parameters**
3447
3448| Name| Description|
3449| -------- | -------- |
3450| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3451| delayTimeList | Pointer to the delay time array. |
3452| delayTimeListLength | Length of the delay time array. |
3453
3454**Returns**
3455
3456Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3457
3458
3459### OH_PackingOptionsForSequence_GetDisposalTypes()
3460
3461```
3462Image_ErrorCode OH_PackingOptionsForSequence_GetDisposalTypes(OH_PackingOptionsForSequence *options, uint32_t *disposalTypes, size_t disposalTypesLength)
3463```
3464
3465**Description**
3466
3467Obtains the disposal type array for image sequence encoding.
3468
3469**Since**: 13
3470
3471**Parameters**
3472
3473| Name| Description|
3474| -------- | -------- |
3475| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3476| disposalTypes | Pointer to the disposal type array. |
3477| disposalTypesLength | Length of the disposal type array. |
3478
3479**Returns**
3480
3481Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3482
3483
3484### OH_PackingOptionsForSequence_GetFrameCount()
3485
3486```
3487Image_ErrorCode OH_PackingOptionsForSequence_GetFrameCount(OH_PackingOptionsForSequence *options, uint32_t *frameCount)
3488```
3489
3490**Description**
3491
3492Obtains the number of frames for packing.
3493
3494**Since**: 13
3495
3496**Parameters**
3497
3498| Name| Description|
3499| -------- | -------- |
3500| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3501| frameCount | Pointer to the number of frames. |
3502
3503**Returns**
3504
3505Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3506
3507
3508### OH_PackingOptionsForSequence_GetLoopCount()
3509
3510```
3511Image_ErrorCode OH_PackingOptionsForSequence_GetLoopCount(OH_PackingOptionsForSequence *options, uint32_t *loopCount)
3512```
3513
3514**Description**
3515
3516Obtains the number of loops for image sequence encoding.
3517
3518**Since**: 13
3519
3520**Parameters**
3521
3522| Name| Description|
3523| -------- | -------- |
3524| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3525| loopCount | Pointer to the number of loops. |
3526
3527**Returns**
3528
3529Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3530
3531
3532### OH_PackingOptionsForSequence_Release()
3533
3534```
3535Image_ErrorCode OH_PackingOptionsForSequence_Release(OH_PackingOptionsForSequence *options)
3536```
3537
3538**Description**
3539
3540Releases the pointer to an **OH_PackingOptionsForSequence** object.
3541
3542**Since**: 13
3543
3544**Parameters**
3545
3546| Name| Description|
3547| -------- | -------- |
3548| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3549
3550**Returns**
3551
3552Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3553
3554
3555### OH_PackingOptionsForSequence_SetDelayTimeList()
3556
3557```
3558Image_ErrorCode OH_PackingOptionsForSequence_SetDelayTimeList(OH_PackingOptionsForSequence *options, int32_t *delayTimeList, size_t delayTimeListLength)
3559```
3560
3561**Description**
3562
3563Sets the delay time array of images for encoding.
3564
3565**Since**: 13
3566
3567**Parameters**
3568
3569| Name| Description|
3570| -------- | -------- |
3571| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3572| delayTimeList | Pointer to the delay time array. |
3573| delayTimeListLength | Length of the delay time array. |
3574
3575**Returns**
3576
3577Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3578
3579
3580### OH_PackingOptionsForSequence_SetDisposalTypes()
3581
3582```
3583Image_ErrorCode OH_PackingOptionsForSequence_SetDisposalTypes(OH_PackingOptionsForSequence *options, uint32_t *disposalTypes, size_t disposalTypesLength)
3584```
3585
3586**Description**
3587
3588Sets the disposal type array for image sequence encoding.
3589
3590**Since**: 13
3591
3592**Parameters**
3593
3594| Name| Description|
3595| -------- | -------- |
3596| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3597| disposalTypes | Pointer to the disposal type array. |
3598| disposalTypesLength | Length of the disposal type array. |
3599
3600**Returns**
3601
3602Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3603
3604
3605### OH_PackingOptionsForSequence_SetFrameCount()
3606
3607```
3608mage_ErrorCode OH_PackingOptionsForSequence_SetFrameCount(OH_PackingOptionsForSequence *options, uint32_t frameCount)
3609```
3610
3611**Description**
3612
3613Sets the number of frames for image sequence encoding.
3614
3615**Since**: 13
3616
3617**Parameters**
3618
3619| Name| Description|
3620| -------- | -------- |
3621| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3622| frameCount | Number of frames. |
3623
3624**Returns**
3625
3626Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3627
3628
3629### OH_PackingOptionsForSequence_SetLoopCount()
3630
3631```
3632Image_ErrorCode OH_PackingOptionsForSequence_SetLoopCount(OH_PackingOptionsForSequence *options, uint32_t loopCount)
3633```
3634
3635**Description**
3636
3637Sets the number of loops for image sequence encoding.
3638
3639**Since**: 13
3640
3641**Parameters**
3642
3643| Name| Description|
3644| -------- | -------- |
3645| options | Pointer to an **OH_PackingOptionsForSequence** struct. |
3646| loopCount | Number of loops. |
3647
3648**Returns**
3649
3650Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3651
3652
3653### OH_PictureMetadata_Clone()
3654
3655```
3656Image_ErrorCode OH_PictureMetadata_Clone(OH_PictureMetadata *oldMetadata, OH_PictureMetadata **newMetadata)
3657```
3658
3659**Description**
3660
3661Clones metadata.
3662
3663**Since**: 13
3664
3665**Parameters**
3666
3667| Name| Description|
3668| -------- | -------- |
3669| oldMetadata | Pointer to an **OH_PictureMetadata** struct. |
3670| newMetadata | Double pointer to the **OH_PictureMetadata** struct obtained. |
3671
3672**Returns**
3673
3674Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_ALLOC_FAILED** if the memory allocation fails; returns **IMAGE_COPY_FAILED** if the memory copy fails. For details, see [Image_ErrorCode](#image_errorcode).
3675
3676
3677### OH_PictureMetadata_Create()
3678
3679```
3680Image_ErrorCode OH_PictureMetadata_Create(Image_MetadataType metadataType, OH_PictureMetadata **metadata)
3681```
3682
3683**Description**
3684
3685Creates the pointer to an **OH_PictureMetadata** struct.
3686
3687**Since**: 13
3688
3689**Parameters**
3690
3691| Name| Description|
3692| -------- | -------- |
3693| metadataType | Metadata type. |
3694| metadata | Double pointer to the **OH_PictureMetadata** struct created. |
3695
3696**Returns**
3697
3698Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3699
3700
3701### OH_PictureMetadata_GetProperty()
3702
3703```
3704Image_ErrorCode OH_PictureMetadata_GetProperty(OH_PictureMetadata *metadata, Image_String *key, Image_String *value)
3705```
3706
3707**Description**
3708
3709Obtains a property of metadata based on the key.
3710
3711**Since**: 13
3712
3713**Parameters**
3714
3715| Name| Description|
3716| -------- | -------- |
3717| metadata | Pointer to an **OH_PictureMetadata** struct. |
3718| key | Pointer to the key of the property. |
3719| value | Pointer to the value of the property. |
3720
3721**Returns**
3722
3723Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported or the metadata type does not match the auxiliary picture type. For details, see [Image_ErrorCode](#image_errorcode).
3724
3725
3726### OH_PictureMetadata_Release()
3727
3728```
3729Image_ErrorCode OH_PictureMetadata_Release(OH_PictureMetadata *metadata)
3730```
3731
3732**Description**
3733
3734Releases the pointer to an **OH_PictureMetadata** struct.
3735
3736**Since**: 13
3737
3738**Parameters**
3739
3740| Name| Description|
3741| -------- | -------- |
3742| metadata | Pointer to an **OH_PictureMetadata** struct. |
3743
3744**Returns**
3745
3746Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3747
3748
3749### OH_PictureMetadata_SetProperty()
3750
3751```
3752Image_ErrorCode OH_PictureMetadata_SetProperty(OH_PictureMetadata *metadata, Image_String *key, Image_String *value)
3753```
3754
3755**Description**
3756
3757Sets a property of metadata based on the key.
3758
3759**Since**: 13
3760
3761**Parameters**
3762
3763| Name| Description|
3764| -------- | -------- |
3765| metadata | Pointer to an **OH_PictureMetadata** struct. |
3766| key | Pointer to the key of the property. |
3767| value | Pointer to the value of the property. |
3768
3769**Returns**
3770
3771Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported or the metadata type does not match the auxiliary picture type. For details, see [Image_ErrorCode](#image_errorcode).
3772
3773
3774### OH_PictureNative_CreatePicture()
3775
3776```
3777Image_ErrorCode OH_PictureNative_CreatePicture(OH_PixelmapNative *mainPixelmap, OH_PictureNative **picture)
3778```
3779
3780**Description**
3781
3782Creates the pointer to an **OH_PictureNative** object.
3783
3784**Since**: 13
3785
3786**Parameters**
3787
3788| Name| Description|
3789| -------- | -------- |
3790| mainPixelmap | Pointer to the **OH_PixelmapNative** object of the main picture. |
3791| picture | Double pointer to the **OH_PictureNative** object created. |
3792
3793**Returns**
3794
3795Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3796
3797
3798### OH_PictureNative_GetAuxiliaryPicture()
3799
3800```
3801Image_ErrorCode OH_PictureNative_GetAuxiliaryPicture(OH_PictureNative *picture, Image_AuxiliaryPictureType type, OH_AuxiliaryPictureNative **auxiliaryPicture)
3802```
3803
3804**Description**
3805
3806Obtains an auxiliary picture by type.
3807
3808**Since**: 13
3809
3810**Parameters**
3811
3812| Name| Description|
3813| -------- | -------- |
3814| picture | Pointer to an **OH_PictureNative** object. |
3815| type | Type of the auxiliary picture. |
3816| auxiliaryPicture | Double pointer to the **OH_AuxiliaryPictureNative** object obtained. |
3817
3818**Returns**
3819
3820Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3821
3822
3823### OH_PictureNative_GetGainmapPixelmap()
3824
3825```
3826Image_ErrorCode OH_PictureNative_GetGainmapPixelmap(OH_PictureNative *picture, OH_PixelmapNative **gainmapPixelmap)
3827```
3828
3829**Description**
3830
3831Obtains the pointer to an **OH_PixelmapNative** object of a gain map.
3832
3833**Since**: 13
3834
3835**Parameters**
3836
3837| Name| Description|
3838| -------- | -------- |
3839| picture | Pointer to an **OH_PictureNative** object. |
3840| gainmapPixelmap | Double pointer to the **OH_PixelmapNative** object of the gain map. |
3841
3842**Returns**
3843
3844Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3845
3846
3847### OH_PictureNative_GetHdrComposedPixelmap()
3848
3849```
3850Image_ErrorCode OH_PictureNative_GetHdrComposedPixelmap(OH_PictureNative *picture, OH_PixelmapNative **hdrPixelmap)
3851```
3852
3853**Description**
3854
3855Obtains the pointer to **OH_PixelmapNative** of an HDR picture.
3856
3857**Since**: 13
3858
3859**Parameters**
3860
3861| Name| Description|
3862| -------- | -------- |
3863| picture | Pointer to an **OH_PictureNative** object. |
3864| hdrPixelmap | Double pointer to the **OH_PixelmapNative** object of the HDR picture. |
3865
3866**Returns**
3867
3868Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_OPERATION** if the operation is not supported, for example, the picture object does not contain a gain map. For details, see [Image_ErrorCode](#image_errorcode).
3869
3870
3871### OH_PictureNative_GetMainPixelmap()
3872
3873```
3874Image_ErrorCode OH_PictureNative_GetMainPixelmap(OH_PictureNative *picture, OH_PixelmapNative **mainPixelmap)
3875```
3876
3877**Description**
3878
3879Obtains the pointer to an **OH_PixelmapNative** object of a main picture.
3880
3881**Since**: 13
3882
3883**Parameters**
3884
3885| Name| Description|
3886| -------- | -------- |
3887| picture | Pointer to an **OH_PictureNative** object. |
3888| mainPixelmap | Double pointer to the **OH_PixelmapNative** object obtained. |
3889
3890**Returns**
3891
3892Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3893
3894
3895### OH_PictureNative_GetMetadata()
3896
3897```
3898Image_ErrorCode OH_PictureNative_GetMetadata(OH_PictureNative *picture, Image_MetadataType metadataType, OH_PictureMetadata **metadata)
3899```
3900
3901**Description**
3902
3903Obtains the metadata of a main picture.
3904
3905**Since**: 13
3906
3907**Parameters**
3908
3909| Name| Description|
3910| -------- | -------- |
3911| picture | Pointer to an **OH_PictureNative** object. |
3912| metadataType | Metadata type. |
3913| metadata | Double pointer to the metadata of the picture. |
3914
3915**Returns**
3916
3917Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported. For details, see [Image_ErrorCode](#image_errorcode).
3918
3919
3920### OH_PictureNative_Release()
3921
3922```
3923Image_ErrorCode OH_PictureNative_Release(OH_PictureNative *picture)
3924```
3925
3926**Description**
3927
3928Releases the pointer to an **OH_PictureNative** object.
3929
3930**Since**: 13
3931
3932**Parameters**
3933
3934| Name| Description|
3935| -------- | -------- |
3936| picture | Pointer to an **OH_PictureNative** object. |
3937
3938**Returns**
3939
3940Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3941
3942
3943### OH_PictureNative_SetAuxiliaryPicture()
3944
3945```
3946Image_ErrorCode OH_PictureNative_SetAuxiliaryPicture(OH_PictureNative *picture, Image_AuxiliaryPictureType type, OH_AuxiliaryPictureNative *auxiliaryPicture)
3947```
3948
3949**Description**
3950
3951Sets an auxiliary picture.
3952
3953**Since**: 13
3954
3955**Parameters**
3956
3957| Name| Description|
3958| -------- | -------- |
3959| picture | Pointer to an **OH_PictureNative** object. |
3960| type | Type of the auxiliary picture. |
3961| auxiliaryPicture | Pointer to an **OH_AuxiliaryPictureNative** object. |
3962
3963**Returns**
3964
3965Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
3966
3967
3968### OH_PictureNative_SetMetadata()
3969
3970```
3971Image_ErrorCode OH_PictureNative_SetMetadata(OH_PictureNative *picture, Image_MetadataType metadataType, OH_PictureMetadata *metadata)
3972```
3973
3974**Description**
3975
3976Sets the metadata for a main picture.
3977
3978**Since**: 13
3979
3980**Parameters**
3981
3982| Name| Description|
3983| -------- | -------- |
3984| picture | Pointer to an **OH_PictureNative** object. |
3985| metadataType | Metadata type. |
3986| metadata | Pointer to the metadata. |
3987
3988**Returns**
3989
3990Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_METADATA** if the metadata type is not supported. For details, see [Image_ErrorCode](#image_errorcode).
3991
3992
3993### OH_PixelmapImageInfo_Create()
3994
3995```
3996Image_ErrorCode OH_PixelmapImageInfo_Create(OH_Pixelmap_ImageInfo **info)
3997```
3998
3999**Description**
4000
4001Creates the pointer to an **OH_Pixelmap_ImageInfo** struct.
4002
4003**Since**: 12
4004
4005**Parameters**
4006
4007| Name| Description|
4008| -------- | -------- |
4009| info | Double pointer to the **OH_Pixelmap_ImageInfo** struct created. |
4010
4011**Returns**
4012
4013Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4014
4015
4016### OH_PixelmapImageInfo_GetAlphaType()
4017
4018```
4019Image_ErrorCode OH_PixelmapImageInfo_GetAlphaType(OH_Pixelmap_ImageInfo *info, int32_t *alphaType)
4020```
4021
4022**Description**
4023
4024Obtains the alpha type.
4025
4026**Since**: 12
4027
4028**Parameters**
4029
4030| Name| Description|
4031| -------- | -------- |
4032| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4033| alphaType | Pointer to the alpha type. For details about the available options, see [PIXELMAP_ALPHA_TYPE](#pixelmap_alpha_type). |
4034
4035**Returns**
4036
4037Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4038
4039
4040### OH_PixelmapImageInfo_GetDynamicRange()
4041
4042```
4043Image_ErrorCode OH_PixelmapImageInfo_GetDynamicRange(OH_Pixelmap_ImageInfo *info, bool *isHdr)
4044```
4045
4046**Description**
4047
4048Obtains the dynamic range of a PixelMap.
4049
4050**Since**: 12
4051
4052**Parameters**
4053
4054| Name| Description|
4055| -------- | -------- |
4056| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4057| isHdr | Pointer to a Boolean that specifies whether the HDR is used. |
4058
4059**Returns**
4060
4061Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4062
4063
4064### OH_PixelmapImageInfo_GetHeight()
4065
4066```
4067Image_ErrorCode OH_PixelmapImageInfo_GetHeight(OH_Pixelmap_ImageInfo *info, uint32_t *height)
4068```
4069
4070**Description**
4071
4072Obtains the image height.
4073
4074**Since**: 12
4075
4076**Parameters**
4077
4078| Name| Description|
4079| -------- | -------- |
4080| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4081| height | Pointer to the image height, in px. |
4082
4083**Returns**
4084
4085Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4086
4087
4088### OH_PixelmapImageInfo_GetPixelFormat()
4089
4090```
4091Image_ErrorCode OH_PixelmapImageInfo_GetPixelFormat(OH_Pixelmap_ImageInfo *info, int32_t *pixelFormat)
4092```
4093
4094**Description**
4095
4096Obtains the pixel format.
4097
4098**Since**: 12
4099
4100**Parameters**
4101
4102| Name| Description|
4103| -------- | -------- |
4104| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4105| pixelFormat | Pointer to the pixel format. |
4106
4107**Returns**
4108
4109Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4110
4111
4112### OH_PixelmapImageInfo_GetRowStride()
4113
4114```
4115Image_ErrorCode OH_PixelmapImageInfo_GetRowStride(OH_Pixelmap_ImageInfo *info, uint32_t *rowStride)
4116```
4117
4118**Description**
4119
4120Obtains the row stride.
4121
4122**Since**: 12
4123
4124**Parameters**
4125
4126| Name| Description|
4127| -------- | -------- |
4128| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4129| rowStride | Pointer to the row stride, which is the number of bytes from one row of pixels in memory to the next row of pixels in memory. |
4130
4131**Returns**
4132
4133Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4134
4135
4136### OH_PixelmapImageInfo_GetWidth()
4137
4138```
4139Image_ErrorCode OH_PixelmapImageInfo_GetWidth(OH_Pixelmap_ImageInfo *info, uint32_t *width)
4140```
4141
4142**Description**
4143
4144Obtains the image width.
4145
4146**Since**: 12
4147
4148**Parameters**
4149
4150| Name| Description|
4151| -------- | -------- |
4152| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4153| width | Pointer to the image width, in px. |
4154
4155**Returns**
4156
4157Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4158
4159
4160### OH_PixelmapImageInfo_Release()
4161
4162```
4163Image_ErrorCode OH_PixelmapImageInfo_Release(OH_Pixelmap_ImageInfo *info)
4164```
4165
4166**Description**
4167
4168Releases the pointer to an **OH_Pixelmap_ImageInfo** struct.
4169
4170**Since**: 12
4171
4172**Parameters**
4173
4174| Name| Description|
4175| -------- | -------- |
4176| info | Pointer to an **OH_Pixelmap_ImageInfo** struct. |
4177
4178**Returns**
4179
4180Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4181
4182
4183### OH_PixelmapInitializationOptions_Create()
4184
4185```
4186Image_ErrorCode OH_PixelmapInitializationOptions_Create(OH_Pixelmap_InitializationOptions **options)
4187```
4188
4189**Description**
4190
4191Creates the pointer to an **OH_Pixelmap_InitializationOptions** struct.
4192
4193**Since**: 12
4194
4195**Parameters**
4196
4197| Name| Description|
4198| -------- | -------- |
4199| options | Double pointer to the **OH_Pixelmap_InitializationOptions** struct created. |
4200
4201**Returns**
4202
4203Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4204
4205
4206### OH_PixelmapInitializationOptions_GetAlphaType()
4207
4208```
4209Image_ErrorCode OH_PixelmapInitializationOptions_GetAlphaType(OH_Pixelmap_InitializationOptions *options, int32_t *alphaType)
4210```
4211
4212**Description**
4213
4214Obtains the alpha type.
4215
4216**Since**: 12
4217
4218**Parameters**
4219
4220| Name| Description|
4221| -------- | -------- |
4222| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4223| alphaType | Pointer to the alpha type. For details about the available options, see [PIXELMAP_ALPHA_TYPE](#pixelmap_alpha_type). |
4224
4225**Returns**
4226
4227Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4228
4229
4230### OH_PixelmapInitializationOptions_GetHeight()
4231
4232```
4233Image_ErrorCode OH_PixelmapInitializationOptions_GetHeight(OH_Pixelmap_InitializationOptions *options, uint32_t *height)
4234```
4235
4236**Description**
4237
4238Obtains the image height.
4239
4240**Since**: 12
4241
4242**Parameters**
4243
4244| Name| Description|
4245| -------- | -------- |
4246| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4247| height | Pointer to the image height, in px. |
4248
4249**Returns**
4250
4251Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4252
4253
4254### OH_PixelmapInitializationOptions_GetPixelFormat()
4255
4256```
4257Image_ErrorCode OH_PixelmapInitializationOptions_GetPixelFormat(OH_Pixelmap_InitializationOptions *options, int32_t *pixelFormat)
4258```
4259
4260**Description**
4261
4262Obtains the pixel format.
4263
4264**Since**: 12
4265
4266**Parameters**
4267
4268| Name| Description|
4269| -------- | -------- |
4270| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4271| pixelFormat | Pointer to the pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format).|
4272
4273**Returns**
4274
4275Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4276
4277
4278### OH_PixelmapInitializationOptions_GetRowStride()
4279
4280```
4281Image_ErrorCode OH_PixelmapInitializationOptions_GetRowStride(OH_Pixelmap_InitializationOptions *options, int32_t *rowStride)
4282```
4283
4284**Description**
4285
4286Obtains the row stride.
4287
4288The stride is the actual memory size occupied by each row of the image, in bytes. Stride = Width \*Number of bytes per pixel + Padding, where padding refers to the extra space added at the end of each row for memory alignment purposes.
4289
4290**Since**: 12
4291
4292**Parameters**
4293
4294| Name| Description|
4295| -------- | -------- |
4296| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4297| rowStride | Pointer to the stride, in bytes. |
4298
4299**Returns**
4300
4301Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if the object pointed to by **options** is released. For details, see [Image_ErrorCode](#image_errorcode).
4302
4303
4304### OH_PixelmapInitializationOptions_GetSrcPixelFormat()
4305
4306```
4307Image_ErrorCode OH_PixelmapInitializationOptions_GetSrcPixelFormat(OH_Pixelmap_InitializationOptions *options, int32_t *srcpixelFormat)
4308```
4309
4310**Description**
4311
4312Obtains the source pixel format.
4313
4314**Since**: 12
4315
4316**Parameters**
4317
4318| Name| Description|
4319| -------- | -------- |
4320| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4321| srcpixelFormat | Pointer to the source pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format). |
4322
4323**Returns**
4324
4325Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4326
4327
4328### OH_PixelmapInitializationOptions_GetWidth()
4329
4330```
4331Image_ErrorCode OH_PixelmapInitializationOptions_GetWidth(OH_Pixelmap_InitializationOptions *options, uint32_t *width)
4332```
4333
4334**Description**
4335
4336Obtains the image width.
4337
4338**Since**: 12
4339
4340**Parameters**
4341
4342| Name| Description|
4343| -------- | -------- |
4344| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4345| width | Pointer to the image width, in px. |
4346
4347**Returns**
4348
4349Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4350
4351
4352### OH_PixelmapInitializationOptions_Release()
4353
4354```
4355Image_ErrorCode OH_PixelmapInitializationOptions_Release(OH_Pixelmap_InitializationOptions *options)
4356```
4357
4358**Description**
4359
4360Releases the pointer to an **OH_Pixelmap_InitializationOptions** struct.
4361
4362**Since**: 12
4363
4364**Parameters**
4365
4366| Name| Description|
4367| -------- | -------- |
4368| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4369
4370**Returns**
4371
4372Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4373
4374
4375### OH_PixelmapInitializationOptions_SetAlphaType()
4376
4377```
4378Image_ErrorCode OH_PixelmapInitializationOptions_SetAlphaType(OH_Pixelmap_InitializationOptions *options, int32_t alphaType)
4379```
4380
4381**Description**
4382
4383Sets the alpha type.
4384
4385**Since**: 12
4386
4387**Parameters**
4388
4389| Name| Description|
4390| -------- | -------- |
4391| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4392| alphaType | Alpha type. For details about the available options, see [PIXELMAP_ALPHA_TYPE](#pixelmap_alpha_type). |
4393
4394**Returns**
4395
4396Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4397
4398
4399### OH_PixelmapInitializationOptions_SetHeight()
4400
4401```
4402Image_ErrorCode OH_PixelmapInitializationOptions_SetHeight(OH_Pixelmap_InitializationOptions *options, uint32_t height)
4403```
4404
4405**Description**
4406
4407Sets the image height.
4408
4409**Since**: 12
4410
4411**Parameters**
4412
4413| Name| Description|
4414| -------- | -------- |
4415| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4416| height | Image height, in px. |
4417
4418**Returns**
4419
4420Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4421
4422
4423### OH_PixelmapInitializationOptions_SetPixelFormat()
4424
4425```
4426Image_ErrorCode OH_PixelmapInitializationOptions_SetPixelFormat(OH_Pixelmap_InitializationOptions *options, int32_t pixelFormat)
4427```
4428
4429**Description**
4430
4431Sets the pixel format.
4432
4433**Since**: 12
4434
4435**Parameters**
4436
4437| Name| Description|
4438| -------- | -------- |
4439| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4440| pixelFormat | Pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format).|
4441
4442**Returns**
4443
4444Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4445
4446
4447### OH_PixelmapInitializationOptions_SetRowStride()
4448
4449```
4450Image_ErrorCode OH_PixelmapInitializationOptions_SetRowStride(OH_Pixelmap_InitializationOptions *options, int32_t rowStride)
4451```
4452
4453**Description**
4454
4455Sets the row stride.
4456
4457The stride is the actual memory size occupied by each row of the image, in bytes. Stride = Width \*Number of bytes per pixel + Padding, where padding refers to the extra space added at the end of each row for memory alignment purposes.
4458
4459**Since**: 12
4460
4461**Parameters**
4462
4463| Name| Description|
4464| -------- | -------- |
4465| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4466| rowStride | Pointer to the stride, in bytes. |
4467
4468**Returns**
4469
4470Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if the object pointed to by **options** is released. For details, see [Image_ErrorCode](#image_errorcode).
4471
4472
4473### OH_PixelmapInitializationOptions_SetSrcPixelFormat()
4474
4475```
4476Image_ErrorCode OH_PixelmapInitializationOptions_SetSrcPixelFormat(OH_Pixelmap_InitializationOptions *options, int32_t srcpixelFormat)
4477```
4478
4479**Description**
4480
4481Sets the source pixel format.
4482
4483**Since**: 12
4484
4485**Parameters**
4486
4487| Name| Description|
4488| -------- | -------- |
4489| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4490| srcpixelFormat | Source pixel format. For details about the available options, see [PIXEL_FORMAT](#pixel_format). |
4491
4492**Returns**
4493
4494Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4495
4496
4497### OH_PixelmapInitializationOptions_SetWidth()
4498
4499```
4500Image_ErrorCode OH_PixelmapInitializationOptions_SetWidth(OH_Pixelmap_InitializationOptions *options, uint32_t width)
4501```
4502
4503**Description**
4504
4505Sets the image width.
4506
4507**Since**: 12
4508
4509**Parameters**
4510
4511| Name| Description|
4512| -------- | -------- |
4513| options | Pointer to an **OH_Pixelmap_InitializationOptions** struct. |
4514| width | Image width, in px. |
4515
4516**Returns**
4517
4518Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4519
4520
4521### OH_PixelmapNative_ConvertAlphaFormat()
4522
4523```
4524Image_ErrorCode OH_PixelmapNative_ConvertAlphaFormat(OH_PixelmapNative* srcpixelmap, OH_PixelmapNative* dstpixelmap, const bool isPremul)
4525```
4526
4527**Description**
4528
4529Converts pixel data of a PixelMap from premultiplied alpha to non-premultiplied alpha, or vice versa.
4530
4531**Since**: 12
4532
4533**Parameters**
4534
4535| Name| Description|
4536| -------- | -------- |
4537| srcpixelmap | Pointer to the source PixelMap, which is an **OH_PixelmapNative** object. |
4538| dstpixelmap | Pointer to the destination PixelMap, which is an **OH_PixelmapNative** object. This pointer must be different from the pointer to the source PixelMap. |
4539| isPremul | Conversion mode. The value **true** means a conversion from premultiplied alpha to non-premultiplied alpha, and **false** means a conversion from non-premultiplied alpha to premultiplied alpha. |
4540
4541**Returns**
4542
4543Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4544
4545
4546### OH_PixelmapNative_ConvertPixelmapNativeFromNapi()
4547
4548```
4549Image_ErrorCode OH_PixelmapNative_ConvertPixelmapNativeFromNapi(napi_env env, napi_value pixelmapNapi, OH_PixelmapNative **pixelmapNative)
4550```
4551
4552**Description**
4553
4554Converts a **PixelMapnapi** object to a **nativePixelMap** object.
4555
4556**Since**: 12
4557
4558**Parameters**
4559
4560| Name| Description|
4561| -------- | -------- |
4562| env | Pointer to the NAPI environment. |
4563| pixelmapNapi | **PixelMapnapi** object. |
4564| pixelmapNative | Double pointer to the **OH_PixelmapNative** object. |
4565
4566**Returns**
4567
4568Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if **pixelmapNative** is a null pointer or is not a **PixelMapNapi** object. For details, see [Image_ErrorCode](#image_errorcode).
4569
4570
4571### OH_PixelmapNative_ConvertPixelmapNativeToNapi()
4572
4573```
4574Image_ErrorCode OH_PixelmapNative_ConvertPixelmapNativeToNapi(napi_env env, OH_PixelmapNative *pixelmapNative, napi_value *pixelmapNapi)
4575```
4576
4577**Description**
4578
4579Converts a **nativePixelMap** object to a **PixelMapnapi** object.
4580
4581**Since**: 12
4582
4583**Parameters**
4584
4585| Name| Description|
4586| -------- | -------- |
4587| env | Pointer to the NAPI environment. |
4588| pixelmapNative | Pointer to an **OH_PixelmapNative** object. |
4589| pixelmapNapi | Double pointer to the **PixelMapnapi** object. |
4590
4591**Returns**
4592
4593Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if **pixelmapNative** is null. For details, see [Image_ErrorCode](#image_errorcode).
4594
4595
4596### OH_PixelmapNative_CreateEmptyPixelmap()
4597
4598```
4599Image_ErrorCode OH_PixelmapNative_CreateEmptyPixelmap(OH_Pixelmap_InitializationOptions *options, OH_PixelmapNative **pixelmap)
4600```
4601
4602**Description**
4603
4604Creates an empty PixelMap using **OH_Pixelmap_InitializationOptions**. The memory data is 0.
4605
4606**Since**: 12
4607
4608**Parameters**
4609
4610| Name| Description|
4611| -------- | -------- |
4612| options | Pointer to the properties. |
4613| pixelmap | Double pointer to the **OH_PixelmapNative** object created. |
4614
4615**Returns**
4616
4617Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4618
4619
4620### OH_PixelmapNative_CreatePixelmap()
4621
4622```
4623Image_ErrorCode OH_PixelmapNative_CreatePixelmap(uint8_t *data, size_t dataLength, OH_Pixelmap_InitializationOptions *options, OH_PixelmapNative **pixelmap)
4624```
4625
4626**Description**
4627
4628Creates a PixelMap based on properties. By default, the BGRA_8888 format is used for data processing. For details about other formats, see [OH_PixelmapInitializationOptions_SetSrcPixelFormat](#oh_pixelmapinitializationoptions_setsrcpixelformat).
4629
4630**Since**: 12
4631
4632**Parameters**
4633
4634| Name| Description|
4635| -------- | -------- |
4636| data | Pointer to the color array in BGRA_8888 format. |
4637| dataLength | Size of the array. |
4638| options | Pointer to the properties. |
4639| pixelmap | Double pointer to the **OH_PixelmapNative** object created. |
4640
4641**Returns**
4642
4643Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_OPERATION** if the operation is not supported. For details, see [Image_ErrorCode](#image_errorcode).
4644
4645
4646### OH_PixelmapNative_Crop()
4647
4648```
4649Image_ErrorCode OH_PixelmapNative_Crop(OH_PixelmapNative *pixelmap, Image_Region *region)
4650```
4651
4652**Description**
4653
4654Crops a PixelMap based on a given size.
4655
4656**Since**: 12
4657
4658**Parameters**
4659
4660| Name| Description|
4661| -------- | -------- |
4662| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4663| region | Pointer to the region of the image after cropping. |
4664
4665**Returns**
4666
4667Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4668
4669
4670### OH_PixelmapNative_Flip()
4671
4672```
4673Image_ErrorCode OH_PixelmapNative_Flip(OH_PixelmapNative *pixelmap, bool shouldFilpHorizontally, bool shouldFilpVertically)
4674```
4675
4676**Description**
4677
4678Flips a PixelMap based on a given angle.
4679
4680**Since**: 12
4681
4682**Parameters**
4683
4684| Name| Description|
4685| -------- | -------- |
4686| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4687| shouldFilpHorizontally | Whether to flip the image horizontally. |
4688| shouldFilpVertically | Whether to flip the image vertically. |
4689
4690**Returns**
4691
4692Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4693
4694
4695
4696### OH_PixelmapNative_GetArgbPixels()
4697
4698```
4699Image_ErrorCode OH_PixelmapNative_GetArgbPixels(OH_PixelmapNative *pixelmap, uint8_t *destination, size_t *bufferSize)
4700```
4701
4702**Description**
4703
4704Reads data in ARGB format from a PixelMap.
4705
4706**Since**: 13
4707
4708**Parameters**
4709
4710| Name| Description|
4711| -------- | -------- |
4712| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4713| destination | Pointer to the buffer to which the pixels will be written. |
4714| bufferSize | Pointer to the buffer size. |
4715
4716**Returns**
4717
4718Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_CONVERSION** if the PixelMap format does not support ARGB data reading; returns **IMAGE_ALLOC_FAILED** if the memory allocation fails; returns **IMAGE_COPY_FAILED** if the memory data fails to be copied, read, or operated. For details, see [Image_ErrorCode](#image_errorcode). For details, see [Image_ErrorCode](#image_errorcode).
4719
4720
4721### OH_PixelmapNative_GetColorSpaceNative()
4722
4723```
4724Image_ErrorCode OH_PixelmapNative_GetColorSpaceNative(OH_PixelmapNative *pixelmap, OH_NativeColorSpaceManager **colorSpaceNative)
4725```
4726
4727**Description**
4728
4729Obtains a **NativeColorSpaceManager** object.
4730
4731**Since**: 13
4732
4733**Parameters**
4734
4735| Name| Description|
4736| -------- | -------- |
4737| pixelmap | Pointer to the source PixelMap of the **NativeColorSpaceManager**. |
4738| colorSpaceNative | Double pointer to the **NativeColorSpaceManager** object obtained. |
4739
4740**Returns**
4741
4742Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4743
4744
4745### OH_PixelmapNative_GetImageInfo()
4746
4747```
4748Image_ErrorCode OH_PixelmapNative_GetImageInfo(OH_PixelmapNative *pixelmap, OH_Pixelmap_ImageInfo *imageInfo)
4749```
4750
4751**Description**
4752
4753Obtains the image information of a PixelMap.
4754
4755**Since**: 12
4756
4757**Parameters**
4758
4759| Name| Description|
4760| -------- | -------- |
4761| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4762| imageInfo | Pointer to the image information. |
4763
4764**Returns**
4765
4766Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4767
4768
4769### OH_PixelmapNative_GetMetadata()
4770
4771```
4772Image_ErrorCode OH_PixelmapNative_GetMetadata(OH_PixelmapNative *pixelmap, OH_Pixelmap_HdrMetadataKey key, OH_Pixelmap_HdrMetadataValue **value)
4773```
4774
4775**Description**
4776
4777Obtains the metadata.
4778
4779**Since**: 12
4780
4781**Parameters**
4782
4783| Name| Description|
4784| -------- | -------- |
4785| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4786| key | Metadata key. For details, see [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey). |
4787| value | Double pointer to the value of the metadata key. For details, see [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md). |
4788
4789**Returns**
4790
4791Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DMA_NOT_EXIST** if the DMA memory does not exist; returns **IMAGE_COPY_FAILED** if the memory copy fails. For details, see [Image_ErrorCode](#image_errorcode).
4792
4793
4794### OH_PixelmapNative_GetNativeBuffer()
4795
4796```
4797Image_ErrorCode OH_PixelmapNative_GetNativeBuffer(OH_PixelmapNative *pixelmap, OH_NativeBuffer **nativeBuffer)
4798```
4799
4800**Description**
4801
4802Obtains the **NativeBuffer** object from a PixelMap in the DMA memory.
4803
4804**Since**: 12
4805
4806**Parameters**
4807
4808| Name| Description|
4809| -------- | -------- |
4810| pixelmap | Pointer to the PixelMap. |
4811| nativeBuffer | Double pointer to the **NativeBuffer** object obtained. |
4812
4813**Returns**
4814
4815Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DMA_NOT_EXIST** if the memory is not the DMA memory; returns **IMAGE_DMA_OPERATION_FAILED** if the operation on the DMA memory fails. For details, see [Image_ErrorCode](#image_errorcode).
4816
4817
4818### OH_PixelmapNative_Opacity()
4819
4820```
4821Image_ErrorCode OH_PixelmapNative_Opacity(OH_PixelmapNative *pixelmap, float rate)
4822```
4823
4824**Description**
4825
4826Sets the opacity rate to enable the PixelMap to achieve the corresponding opacity effect.
4827
4828**Since**: 12
4829
4830**Parameters**
4831
4832| Name| Description|
4833| -------- | -------- |
4834| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4835| rate | Opacity rate to set. |
4836
4837**Returns**
4838
4839Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4840
4841
4842### OH_PixelmapNative_ReadPixels()
4843
4844```
4845Image_ErrorCode OH_PixelmapNative_ReadPixels(OH_PixelmapNative *pixelmap, uint8_t *destination, size_t *bufferSize)
4846```
4847
4848**Description**
4849
4850Reads the pixels of a PixelMap and writes the result to the buffer based on the pixel format of the PixelMap.
4851
4852**Since**: 12
4853
4854**Parameters**
4855
4856| Name| Description|
4857| -------- | -------- |
4858| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4859| destination | Pointer to the buffer to which the pixels will be written. |
4860| bufferSize | Pointer to the buffer size. The buffer size of the RGBA format is equal to width * height * 4, and the buffer size of the NV21 and NV12 formats is equal to width * height+((width+1)/2) * ((height+1)/2) * 2. |
4861
4862**Returns**
4863
4864Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
4865
4866
4867### OH_PixelmapNative_Release()
4868
4869```
4870Image_ErrorCode OH_PixelmapNative_Release(OH_PixelmapNative *pixelmap)
4871```
4872
4873**Description**
4874
4875Releases the pointer to an **OH_PixelmapNative** object.
4876
4877**Since**: 12
4878
4879**Parameters**
4880
4881| Name| Description|
4882| -------- | -------- |
4883| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4884
4885**Returns**
4886
4887Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4888
4889
4890### OH_PixelmapNative_Rotate()
4891
4892```
4893Image_ErrorCode OH_PixelmapNative_Rotate(OH_PixelmapNative *pixelmap, float angle)
4894```
4895
4896**Description**
4897
4898Rotates a PixelMap based on a given angle.
4899
4900**Since**: 12
4901
4902**Parameters**
4903
4904| Name| Description|
4905| -------- | -------- |
4906| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4907| angle | Image rotation angle, in degrees. |
4908
4909**Returns**
4910
4911Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4912
4913
4914### OH_PixelmapNative_Scale()
4915
4916```
4917Image_ErrorCode OH_PixelmapNative_Scale(OH_PixelmapNative *pixelmap, float scaleX, float scaleY)
4918```
4919
4920**Description**
4921
4922Scales a PixelMap based on a given width and height.
4923
4924**Since**: 12
4925
4926**Parameters**
4927
4928| Name| Description|
4929| -------- | -------- |
4930| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4931| scaleX | Scale ratio of the width. |
4932| scaleY | Scale ratio of the height. |
4933
4934**Returns**
4935
4936Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4937
4938
4939### OH_PixelmapNative_ScaleWithAntiAliasing()
4940
4941```
4942Image_ErrorCode OH_PixelmapNative_ScaleWithAntiAliasing(OH_PixelmapNative *pixelmap, float scaleX, float scaleY, OH_PixelmapNative_AntiAliasingLevel level)
4943```
4944
4945**Description**
4946
4947Scales a PixelMap based on the specified anti-aliasing level, width, and height.
4948
4949**Since**: 12
4950
4951**Parameters**
4952
4953| Name| Description|
4954| -------- | -------- |
4955| pixelmap | Pointer to an **OH_PixelmapNative** object. |
4956| scaleX | Scale ratio of the width. |
4957| scaleY | Scale ratio of the height. |
4958| level | Anti-aliasing level. |
4959
4960**Returns**
4961
4962Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_TOO_LARGE** if the image is too large; returns **IMAGE_ALLOC_FAILED** if memory allocation fails; returns **IMAGE_UNKNOWN_ERROR** if the object pointed to by **pixelmap** is released. For details, see [Image_ErrorCode](#image_errorcode).
4963
4964
4965### OH_PixelmapNative_SetColorSpaceNative()
4966
4967```
4968Image_ErrorCode OH_PixelmapNative_SetColorSpaceNative(OH_PixelmapNative *pixelmap, OH_NativeColorSpaceManager *colorSpaceNative)
4969```
4970
4971**Description**
4972
4973Sets a **NativeColorSpaceManager** object.
4974
4975**Since**: 13
4976
4977**Parameters**
4978
4979| Name| Description|
4980| -------- | -------- |
4981| pixelmap | Pointer to the target PixelMap of the **NativeColorSpaceManager** object. |
4982| colorSpaceNative | Pointer to a **NativeColorSpaceManager** object. |
4983
4984**Returns**
4985
4986Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
4987
4988
4989### OH_PixelmapNative_SetMemoryName()
4990
4991```
4992Image_ErrorCode OH_PixelmapNative_SetMemoryName(OH_PixelmapNative *pixelmap, char *name, size_t *size)
4993```
4994
4995**Description**
4996
4997Sets the memory name of a PixelMap.
4998
4999**Since**: 13
5000
5001**Parameters**
5002
5003| Name| Description|
5004| -------- | -------- |
5005| pixelmap | Pointer to an **OH_PixelmapNative** object. |
5006| name | Pointer to the memory name. |
5007| size | Pointer to the memory size (in bytes). |
5008
5009**Returns**
5010
5011Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if the name length exceeds 31 characters or is less than 1 character; Returns **IMAGE_UNSUPPORTED_MEMORY_FORMAT** if the memory is neither DMA memory nor ASHMEM memory. For details, see [Image_ErrorCode](#image_errorcode).
5012
5013
5014### OH_PixelmapNative_SetMetadata()
5015
5016```
5017Image_ErrorCode OH_PixelmapNative_SetMetadata(OH_PixelmapNative *pixelmap, OH_Pixelmap_HdrMetadataKey key, OH_Pixelmap_HdrMetadataValue *value)
5018```
5019
5020**Description**
5021
5022Sets the metadata.
5023
5024**Since**: 12
5025
5026**Parameters**
5027
5028| Name| Description|
5029| -------- | -------- |
5030| pixelmap | Pointer to an **OH_PixelmapNative** object. |
5031| key | Metadata key. For details, see [OH_Pixelmap_HdrMetadataKey](#oh_pixelmap_hdrmetadatakey). |
5032| value | Pointer to the value of the metadata key. For details, see [OH_Pixelmap_HdrMetadataValue](_o_h___pixelmap___hdr_metadata_value.md). |
5033
5034**Returns**
5035
5036Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_DMA_NOT_EXIST** if the DMA memory does not exist; returns **IMAGE_COPY_FAILED** if the memory copy fails. For details, see [Image_ErrorCode](#image_errorcode).
5037
5038
5039### OH_PixelmapNative_ToSdr()
5040
5041```
5042Image_ErrorCode OH_PixelmapNative_ToSdr(OH_PixelmapNative *pixelmap)
5043```
5044
5045**Description**
5046
5047Converts a PixelMap from the HDR format to the SDR format.
5048
5049**Since**: 12
5050
5051**Parameters**
5052
5053| Name| Description|
5054| -------- | -------- |
5055| pixelmap | Pointer to an **OH_PixelmapNative** object. |
5056
5057**Returns**
5058
5059Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_OPERATION** if the operation is not supported. For details, see [Image_ErrorCode](#image_errorcode).
5060
5061
5062### OH_PixelmapNative_Translate()
5063
5064```
5065Image_ErrorCode OH_PixelmapNative_Translate(OH_PixelmapNative *pixelmap, float x, float y)
5066```
5067
5068**Description**
5069
5070Translates a PixelMap based on given coordinates.
5071
5072**Since**: 12
5073
5074**Parameters**
5075
5076| Name| Description|
5077| -------- | -------- |
5078| pixelmap | Pointer to an **OH_PixelmapNative** object. |
5079| x | X coordinate to translate. |
5080| y | Y coordinate to translate. |
5081
5082**Returns**
5083
5084Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect. For details, see [Image_ErrorCode](#image_errorcode).
5085
5086
5087### OH_PixelmapNative_WritePixels()
5088
5089```
5090Image_ErrorCode OH_PixelmapNative_WritePixels(OH_PixelmapNative *pixelmap, uint8_t *source, size_t bufferSize)
5091```
5092
5093**Description**
5094
5095Reads the pixels in the buffer and writes the result to the PixelMap based on the pixel format of the PixelMap.
5096
5097**Since**: 12
5098
5099**Parameters**
5100
5101| Name| Description|
5102| -------- | -------- |
5103| pixelmap | Pointer to an **OH_PixelmapNative** object. |
5104| source | Pointer to the buffer from which the pixels will be read. |
5105| bufferSize | Buffer size. |
5106
5107**Returns**
5108
5109Returns **IMAGE_SUCCESS** if the operation is successful; returns **IMAGE_BAD_PARAMETER** if a parameter is incorrect; returns **IMAGE_UNSUPPORTED_OPERATION** if the operation is not supported; returns **IMAGE_UNKNOWN_ERROR** if an unknown error occurs. For details, see [Image_ErrorCode](#image_errorcode).
5110
5111
5112## Variable Description
5113
5114
5115### MIME_TYPE_BMP
5116
5117```
5118static const char* MIME_TYPE_BMP = "image/bmp"
5119```
5120
5121**Description**
5122
5123BMP image format.
5124
5125**Since**: 12
5126
5127
5128### MIME_TYPE_GIF
5129
5130```
5131static const char* MIME_TYPE_GIF = "image/gif"
5132```
5133
5134**Description**
5135
5136GIF image format.
5137
5138**Since**: 12
5139
5140
5141### MIME_TYPE_HEIC
5142
5143```
5144static const char* MIME_TYPE_HEIC = "image/heic"
5145```
5146
5147**Description**
5148
5149HEIF image format.
5150
5151**Since**: 12
5152
5153
5154### MIME_TYPE_ICON
5155
5156```
5157static const char* MIME_TYPE_ICON = "image/x-icon"
5158```
5159
5160**Description**
5161
5162ICO image format.
5163
5164**Since**: 12
5165
5166
5167### MIME_TYPE_JPEG
5168
5169```
5170static const char* MIME_TYPE_JPEG = "image/jpeg"
5171```
5172
5173**Description**
5174
5175JPEG image format.
5176
5177**Since**: 12
5178
5179
5180### MIME_TYPE_PNG
5181
5182```
5183static const char* MIME_TYPE_PNG = "image/png"
5184```
5185
5186**Description**
5187
5188PNG image format.
5189
5190**Since**: 12
5191
5192
5193### MIME_TYPE_WEBP
5194
5195```
5196static const char* MIME_TYPE_WEBP = "image/webp"
5197```
5198
5199**Description**
5200
5201WebP image format.
5202
5203**Since**: 12
5204
5205
5206### OHOS_IMAGE_PROPERTY_ARTIST
5207
5208```
5209static const char* OHOS_IMAGE_PROPERTY_ARTIST = "Artist"
5210```
5211
5212**Description**
5213
5214Person who created the image.
5215
5216**Since**: 12
5217
5218
5219### OHOS_IMAGE_PROPERTY_BITS_PER_SAMPLE
5220
5221```
5222static const char* OHOS_IMAGE_PROPERTY_BITS_PER_SAMPLE = "BitsPerSample"
5223```
5224
5225**Description**
5226
5227Number of bits per sample.
5228
5229**Since**: 12
5230
5231
5232### OHOS_IMAGE_PROPERTY_BODY_SERIAL_NUMBER
5233
5234```
5235static const char* OHOS_IMAGE_PROPERTY_BODY_SERIAL_NUMBER = "BodySerialNumber"
5236```
5237
5238**Description**
5239
5240Serial number of the camera body.
5241
5242**Since**: 12
5243
5244
5245### OHOS_IMAGE_PROPERTY_BRIGHTNESS_VALUE
5246
5247```
5248static const char* OHOS_IMAGE_PROPERTY_BRIGHTNESS_VALUE = "BrightnessValue"
5249```
5250
5251**Description**
5252
5253Value of brightness, expressed in APEX values.
5254
5255**Since**: 12
5256
5257
5258### OHOS_IMAGE_PROPERTY_BURST_NUMBER
5259
5260```
5261static const char* OHOS_IMAGE_PROPERTY_BURST_NUMBER = "HwMnoteBurstNumber"
5262```
5263
5264**Description**
5265
5266Number of burst shooting times.
5267
5268**Since**: 12
5269
5270
5271### OHOS_IMAGE_PROPERTY_CAMERA_OWNER_NAME
5272
5273```
5274static const char* OHOS_IMAGE_PROPERTY_CAMERA_OWNER_NAME = "CameraOwnerName"
5275```
5276
5277**Description**
5278
5279Name of the camera owner.
5280
5281**Since**: 12
5282
5283
5284### OHOS_IMAGE_PROPERTY_CFA_PATTERN
5285
5286```
5287static const char* OHOS_IMAGE_PROPERTY_CFA_PATTERN = "CFAPattern"
5288```
5289
5290**Description**
5291
5292Color Filter Array (CFA) geometric pattern of the image sensor.
5293
5294**Since**: 12
5295
5296
5297### OHOS_IMAGE_PROPERTY_COLOR_SPACE
5298
5299```
5300static const char* OHOS_IMAGE_PROPERTY_COLOR_SPACE = "ColorSpace"
5301```
5302
5303**Description**
5304
5305Color space information, which is usually recorded as a color space specifier.
5306
5307**Since**: 12
5308
5309
5310### OHOS_IMAGE_PROPERTY_COMPONENTS_CONFIGURATION
5311
5312```
5313static const char* OHOS_IMAGE_PROPERTY_COMPONENTS_CONFIGURATION = "ComponentsConfiguration"
5314```
5315
5316**Description**
5317
5318Specific information about compressed data.
5319
5320**Since**: 12
5321
5322
5323### OHOS_IMAGE_PROPERTY_COMPOSITE_IMAGE
5324
5325```
5326static const char* OHOS_IMAGE_PROPERTY_COMPOSITE_IMAGE = "CompositeImage"
5327```
5328
5329**Description**
5330
5331Whether the image is a composite image.
5332
5333**Since**: 12
5334
5335
5336### OHOS_IMAGE_PROPERTY_COMPRESSED_BITS_PER_PIXEL
5337
5338```
5339static const char* OHOS_IMAGE_PROPERTY_COMPRESSED_BITS_PER_PIXEL = "CompressedBitsPerPixel"
5340```
5341
5342**Description**
5343
5344Number of bits per pixel. It is specific to compressed data.
5345
5346**Since**: 12
5347
5348
5349### OHOS_IMAGE_PROPERTY_COMPRESSION
5350
5351```
5352static const char* OHOS_IMAGE_PROPERTY_COMPRESSION = "Compression"
5353```
5354
5355**Description**
5356
5357Compression scheme used on the image data.
5358
5359**Since**: 12
5360
5361
5362### OHOS_IMAGE_PROPERTY_CONTRAST
5363
5364```
5365static const char* OHOS_IMAGE_PROPERTY_CONTRAST = "Contrast"
5366```
5367
5368**Description**
5369
5370Direction of contrast processing used by the camera.
5371
5372**Since**: 12
5373
5374
5375### OHOS_IMAGE_PROPERTY_COPYRIGHT
5376
5377```
5378static const char* OHOS_IMAGE_PROPERTY_COPYRIGHT = "Copyright"
5379```
5380
5381**Description**
5382
5383Copyright notice of the image.
5384
5385**Since**: 12
5386
5387
5388### OHOS_IMAGE_PROPERTY_CUSTOM_RENDERED
5389
5390```
5391static const char* OHOS_IMAGE_PROPERTY_CUSTOM_RENDERED = "CustomRendered"
5392```
5393
5394**Description**
5395
5396Special processing on image data.
5397
5398**Since**: 12
5399
5400
5401### OHOS_IMAGE_PROPERTY_DATE_TIME_DIGITIZED
5402
5403```
5404static const char* OHOS_IMAGE_PROPERTY_DATE_TIME_DIGITIZED = "DateTimeDigitized"
5405```
5406
5407**Description**
5408
5409Date and time when the image was stored as digital data, in the format of YYYY:MM:DD HH:MM:SS.
5410
5411**Since**: 12
5412
5413
5414### OHOS_IMAGE_PROPERTY_DATE_TIME_ORIGINAL
5415
5416```
5417static const char* OHOS_IMAGE_PROPERTY_DATE_TIME_ORIGINAL = "DateTimeOriginal"
5418```
5419
5420**Description**
5421
5422Shooting time, for example, 2022:09:06 15:48:00.
5423
5424**Since**: 12
5425
5426
5427### OHOS_IMAGE_PROPERTY_DEFAULT_CROP_SIZE
5428
5429```
5430static const char* OHOS_IMAGE_PROPERTY_DEFAULT_CROP_SIZE = "DefaultCropSize"
5431```
5432
5433**Description**
5434
5435Size of the final image area, in raw image coordinates, taking into account extra pixels around the edges of the final image.
5436
5437**Since**: 12
5438
5439
5440### OHOS_IMAGE_PROPERTY_DEVICE_SETTING_DESCRIPTION
5441
5442```
5443static const char* OHOS_IMAGE_PROPERTY_DEVICE_SETTING_DESCRIPTION = "DeviceSettingDescription"
5444```
5445
5446**Description**
5447
5448Information about the photographing conditions of a specific camera model.
5449
5450**Since**: 12
5451
5452
5453### OHOS_IMAGE_PROPERTY_DIGITAL_ZOOM_RATIO
5454
5455```
5456static const char* OHOS_IMAGE_PROPERTY_DIGITAL_ZOOM_RATIO = "DigitalZoomRatio"
5457```
5458
5459**Description**
5460
5461Digital zoom ratio when the image was captured.
5462
5463**Since**: 12
5464
5465
5466### OHOS_IMAGE_PROPERTY_DNG_VERSION
5467
5468```
5469static const char* OHOS_IMAGE_PROPERTY_DNG_VERSION = "DNGVersion"
5470```
5471
5472**Description**
5473
5474DNG version. It encodes the DNG 4-tier version number.
5475
5476**Since**: 12
5477
5478
5479### OHOS_IMAGE_PROPERTY_EXIF_VERSION
5480
5481```
5482static const char* OHOS_IMAGE_PROPERTY_EXIF_VERSION = "ExifVersion"
5483```
5484
5485**Description**
5486
5487Version of the supported EXIF standard.
5488
5489**Since**: 12
5490
5491
5492### OHOS_IMAGE_PROPERTY_EXPOSURE_INDEX
5493
5494```
5495static const char* OHOS_IMAGE_PROPERTY_EXPOSURE_INDEX = "ExposureIndex"
5496```
5497
5498**Description**
5499
5500Exposure index selected at the time the image is captured.
5501
5502**Since**: 12
5503
5504
5505### OHOS_IMAGE_PROPERTY_EXPOSURE_MODE
5506
5507```
5508static const char* OHOS_IMAGE_PROPERTY_EXPOSURE_MODE = "ExposureMode"
5509```
5510
5511**Description**
5512
5513Exposure mode set when the image was captured.
5514
5515**Since**: 12
5516
5517
5518### OHOS_IMAGE_PROPERTY_EXPOSURE_PROGRAM
5519
5520```
5521static const char* OHOS_IMAGE_PROPERTY_EXPOSURE_PROGRAM = "ExposureProgram"
5522```
5523
5524**Description**
5525
5526Class of the program used by the camera to set exposure when the image was captured.
5527
5528**Since**: 12
5529
5530
5531### OHOS_IMAGE_PROPERTY_EXPOSURE_TIME
5532
5533```
5534static const char* OHOS_IMAGE_PROPERTY_EXPOSURE_TIME = "ExposureTime"
5535```
5536
5537**Description**
5538
5539Exposure time, for example, 1/33 seconds.
5540
5541**Since**: 12
5542
5543
5544### OHOS_IMAGE_PROPERTY_F_NUMBER
5545
5546```
5547static const char* OHOS_IMAGE_PROPERTY_F_NUMBER = "FNumber"
5548```
5549
5550**Description**
5551
5552F number, for example, f/1.8.
5553
5554**Since**: 12
5555
5556
5557### OHOS_IMAGE_PROPERTY_FACE_CONF
5558
5559```
5560static const char* OHOS_IMAGE_PROPERTY_FACE_CONF = "HwMnoteFaceConf"
5561```
5562
5563**Description**
5564
5565Face confidence.
5566
5567**Since**: 12
5568
5569
5570### OHOS_IMAGE_PROPERTY_FACE_LEYE_CENTER
5571
5572```
5573static const char* OHOS_IMAGE_PROPERTY_FACE_LEYE_CENTER = "HwMnoteFaceLeyeCenter"
5574```
5575
5576**Description**
5577
5578Left eye centered. It is used in **OH_ImageSource_GetImageProperty** and **OH_ImageSource_ModifyImageProperty**.
5579
5580**Since**: 12
5581
5582
5583### OHOS_IMAGE_PROPERTY_FACE_MOUTH_CENTER
5584
5585```
5586static const char* OHOS_IMAGE_PROPERTY_FACE_MOUTH_CENTER = "HwMnoteFaceMouthCenter"
5587```
5588
5589**Description**
5590
5591Mouth centered.
5592
5593**Since**: 12
5594
5595
5596### OHOS_IMAGE_PROPERTY_FACE_POINTER
5597
5598```
5599static const char* OHOS_IMAGE_PROPERTY_FACE_POINTER = "HwMnoteFacePointer"
5600```
5601
5602**Description**
5603
5604Face pointer.
5605
5606**Since**: 12
5607
5608
5609### OHOS_IMAGE_PROPERTY_FACE_RECT
5610
5611```
5612static const char* OHOS_IMAGE_PROPERTY_FACE_RECT = "HwMnoteFaceRect"
5613```
5614
5615**Description**
5616
5617Face rectangle.
5618
5619**Since**: 12
5620
5621
5622### OHOS_IMAGE_PROPERTY_FACE_REYE_CENTER
5623
5624```
5625static const char* OHOS_IMAGE_PROPERTY_FACE_REYE_CENTER = "HwMnoteFaceReyeCenter"
5626```
5627
5628**Description**
5629
5630Right eye centered.
5631
5632**Since**: 12
5633
5634
5635### OHOS_IMAGE_PROPERTY_FACE_SMILE_SCORE
5636
5637```
5638static const char* OHOS_IMAGE_PROPERTY_FACE_SMILE_SCORE = "HwMnoteFaceSmileScore"
5639```
5640
5641**Description**
5642
5643Smile score of for faces.
5644
5645**Since**: 12
5646
5647
5648### OHOS_IMAGE_PROPERTY_FACE_VERSION
5649
5650```
5651static const char* OHOS_IMAGE_PROPERTY_FACE_VERSION = "HwMnoteFaceVersion"
5652```
5653
5654**Description**
5655
5656Facial recognition algorithm version.
5657
5658**Since**: 12
5659
5660
5661### OHOS_IMAGE_PROPERTY_FILE_SOURCE
5662
5663```
5664static const char* OHOS_IMAGE_PROPERTY_FILE_SOURCE = "FileSource"
5665```
5666
5667**Description**
5668
5669Image source.
5670
5671**Since**: 12
5672
5673
5674### OHOS_IMAGE_PROPERTY_FLASH_ENERGY
5675
5676```
5677static const char* OHOS_IMAGE_PROPERTY_FLASH_ENERGY = "FlashEnergy"
5678```
5679
5680**Description**
5681
5682Strobe energy at the time the image was captured, in Beam Candle Power Seconds (BCPS).
5683
5684**Since**: 12
5685
5686
5687### OHOS_IMAGE_PROPERTY_FLASHPIX_VERSION
5688
5689```
5690static const char* OHOS_IMAGE_PROPERTY_FLASHPIX_VERSION = "FlashpixVersion"
5691```
5692
5693**Description**
5694
5695FlashPix format version supported by an FPXR file. It is used to enhance device compatibility.
5696
5697**Since**: 12
5698
5699
5700### OHOS_IMAGE_PROPERTY_FOCAL_PLANE_RESOLUTION_UNIT
5701
5702```
5703static const char* OHOS_IMAGE_PROPERTY_FOCAL_PLANE_RESOLUTION_UNIT = "FocalPlaneResolutionUnit"
5704```
5705
5706**Description**
5707
5708Unit for measuring FocalPlaneXResolution and FocalPlaneYResolution.
5709
5710**Since**: 12
5711
5712
5713### OHOS_IMAGE_PROPERTY_FOCAL_PLANE_X_RESOLUTION
5714
5715```
5716static const char* OHOS_IMAGE_PROPERTY_FOCAL_PLANE_X_RESOLUTION = "FocalPlaneXResolution"
5717```
5718
5719**Description**
5720
5721Number of pixels in the image width (X) direction per FocalPlaneResolutionUnit.
5722
5723**Since**: 12
5724
5725
5726### OHOS_IMAGE_PROPERTY_FOCAL_PLANE_Y_RESOLUTION
5727
5728```
5729static const char* OHOS_IMAGE_PROPERTY_FOCAL_PLANE_Y_RESOLUTION = "FocalPlaneYResolution"
5730```
5731
5732**Description**
5733
5734Number of pixels in the image height (Y) direction per FocalPlaneResolutionUnit.
5735
5736**Since**: 12
5737
5738
5739### OHOS_IMAGE_PROPERTY_FRAGMENT_HEIGHT
5740
5741```
5742static const char *OHOS_IMAGE_PROPERTY_FRAGMENT_HEIGHT = "FragmentImageHeight"
5743```
5744
5745**Description**
5746
5747Height of the fragment map.
5748
5749**Since**: 13
5750
5751
5752### OHOS_IMAGE_PROPERTY_FRAGMENT_WIDTH
5753
5754```
5755static const char *OHOS_IMAGE_PROPERTY_FRAGMENT_WIDTH = "FragmentImageWidth"
5756```
5757
5758**Description**
5759
5760Width of the fragment map.
5761
5762**Since**: 13
5763
5764
5765### OHOS_IMAGE_PROPERTY_FRONT_CAMERA
5766
5767```
5768static const char* OHOS_IMAGE_PROPERTY_FRONT_CAMERA = "HwMnoteFrontCamera"
5769```
5770
5771**Description**
5772
5773Whether the front camera is used to take a selfie.
5774
5775**Since**: 12
5776
5777
5778### OHOS_IMAGE_PROPERTY_GAIN_CONTROL
5779
5780```
5781static const char* OHOS_IMAGE_PROPERTY_GAIN_CONTROL = "GainControl"
5782```
5783
5784**Description**
5785
5786Degree of overall image gain adjustment.
5787
5788**Since**: 12
5789
5790
5791### OHOS_IMAGE_PROPERTY_GAMMA
5792
5793```
5794static const char* OHOS_IMAGE_PROPERTY_GAMMA = "Gamma"
5795```
5796
5797**Description**
5798
5799Gamma value.
5800
5801**Since**: 12
5802
5803
5804### OHOS_IMAGE_PROPERTY_GIF_LOOP_COUNT
5805
5806```
5807static const char* OHOS_IMAGE_PROPERTY_GIF_LOOP_COUNT = "GIFLoopCount"
5808```
5809
5810**Description**
5811
5812Number of GIF loops.
5813
5814**Since**: 12
5815
5816
5817### OHOS_IMAGE_PROPERTY_GPS_ALTITUDE
5818
5819```
5820static const char* OHOS_IMAGE_PROPERTY_GPS_ALTITUDE = "GPSAltitude"
5821```
5822
5823**Description**
5824
5825Altitude based on the reference in GPSAltitudeRef.
5826
5827**Since**: 12
5828
5829
5830### OHOS_IMAGE_PROPERTY_GPS_ALTITUDE_REF
5831
5832```
5833static const char* OHOS_IMAGE_PROPERTY_GPS_ALTITUDE_REF = "GPSAltitudeRef"
5834```
5835
5836**Description**
5837
5838Whether the latitude is north or south latitude.
5839
5840**Since**: 12
5841
5842
5843### OHOS_IMAGE_PROPERTY_GPS_AREA_INFORMATION
5844
5845```
5846static const char* OHOS_IMAGE_PROPERTY_GPS_AREA_INFORMATION = "GPSAreaInformation"
5847```
5848
5849**Description**
5850
5851String that records the name of the GPS area.
5852
5853**Since**: 12
5854
5855
5856### OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING
5857
5858```
5859static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING = "GPSDestBearing"
5860```
5861
5862**Description**
5863
5864Bearing to the destination point.
5865
5866**Since**: 12
5867
5868
5869### OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING_REF
5870
5871```
5872static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_BEARING_REF = "GPSDestBearingRef"
5873```
5874
5875**Description**
5876
5877Reference of the bearing to the destination point.
5878
5879**Since**: 12
5880
5881
5882### OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE
5883
5884```
5885static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE = "GPSDestDistance"
5886```
5887
5888**Description**
5889
5890Distance to the destination point.
5891
5892**Since**: 12
5893
5894
5895### OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE_REF
5896
5897```
5898static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_DISTANCE_REF = "GPSDestDistanceRef"
5899```
5900
5901**Description**
5902
5903Unit used to express the distance to the destination point.
5904
5905**Since**: 12
5906
5907
5908### OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE
5909
5910```
5911static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE = "GPSDestLatitude"
5912```
5913
5914**Description**
5915
5916Latitude of the destination point.
5917
5918**Since**: 12
5919
5920
5921### OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE_REF
5922
5923```
5924static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_LATITUDE_REF = "GPSDestLatitudeRef"
5925```
5926
5927**Description**
5928
5929Whether the latitude of the destination point is north or south latitude.
5930
5931**Since**: 12
5932
5933
5934### OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE
5935
5936```
5937static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE = "GPSDestLongitude"
5938```
5939
5940**Description**
5941
5942Longitude of the destination point.
5943
5944**Since**: 12
5945
5946
5947### OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE_REF
5948
5949```
5950static const char* OHOS_IMAGE_PROPERTY_GPS_DEST_LONGITUDE_REF = "GPSDestLongitudeRef"
5951```
5952
5953**Description**
5954
5955Whether the longitude of the destination point is east or west longitude.
5956
5957**Since**: 12
5958
5959
5960### OHOS_IMAGE_PROPERTY_GPS_DIFFERENTIAL
5961
5962```
5963static const char* OHOS_IMAGE_PROPERTY_GPS_DIFFERENTIAL = "GPSDifferential"
5964```
5965
5966**Description**
5967
5968Whether differential correction is applied to the GPS receiver. It is critical to accurate location accuracy.
5969
5970**Since**: 12
5971
5972
5973### OHOS_IMAGE_PROPERTY_GPS_DOP
5974
5975```
5976static const char* OHOS_IMAGE_PROPERTY_GPS_DOP = "GPSDOP"
5977```
5978
5979**Description**
5980
5981GPS DOP (data degree of precision)
5982
5983**Since**: 12
5984
5985
5986### OHOS_IMAGE_PROPERTY_GPS_H_POSITIONING_ERROR
5987
5988```
5989static const char* OHOS_IMAGE_PROPERTY_GPS_H_POSITIONING_ERROR = "GPSHPositioningError"
5990```
5991
5992**Description**
5993
5994Horizontal positioning error, in meters.
5995
5996**Since**: 12
5997
5998
5999### OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION
6000
6001```
6002static const char* OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION = "GPSImgDirection"
6003```
6004
6005**Description**
6006
6007Direction of the image when it was captured.
6008
6009**Since**: 12
6010
6011
6012### OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION_REF
6013
6014```
6015static const char* OHOS_IMAGE_PROPERTY_GPS_IMG_DIRECTION_REF = "GPSImgDirectionRef"
6016```
6017
6018**Description**
6019
6020Reference of the direction of the image when it was captured.
6021
6022**Since**: 12
6023
6024
6025### OHOS_IMAGE_PROPERTY_GPS_LATITUDE
6026
6027```
6028static const char* OHOS_IMAGE_PROPERTY_GPS_LATITUDE = "GPSLatitude"
6029```
6030
6031**Description**
6032
6033Image latitude.
6034
6035**Since**: 12
6036
6037
6038### OHOS_IMAGE_PROPERTY_GPS_LATITUDE_REF
6039
6040```
6041static const char* OHOS_IMAGE_PROPERTY_GPS_LATITUDE_REF = "GPSLatitudeRef"
6042```
6043
6044**Description**
6045
6046Whether the latitude is north or south latitude.
6047
6048**Since**: 12
6049
6050
6051### OHOS_IMAGE_PROPERTY_GPS_LONGITUDE
6052
6053```
6054static const char* OHOS_IMAGE_PROPERTY_GPS_LONGITUDE = "GPSLongitude"
6055```
6056
6057**Description**
6058
6059Image longitude.
6060
6061**Since**: 12
6062
6063
6064### OHOS_IMAGE_PROPERTY_GPS_LONGITUDE_REF
6065
6066```
6067static const char* OHOS_IMAGE_PROPERTY_GPS_LONGITUDE_REF = "GPSLongitudeRef"
6068```
6069
6070**Description**
6071
6072Whether the longitude is east or west longitude.
6073
6074**Since**: 12
6075
6076
6077### OHOS_IMAGE_PROPERTY_GPS_MAP_DATUM
6078
6079```
6080static const char* OHOS_IMAGE_PROPERTY_GPS_MAP_DATUM = "GPSMapDatum"
6081```
6082
6083**Description**
6084
6085Geodetic survey data used by the GPS receiver.
6086
6087**Since**: 12
6088
6089
6090### OHOS_IMAGE_PROPERTY_GPS_MEASURE_MODE
6091
6092```
6093static const char* OHOS_IMAGE_PROPERTY_GPS_MEASURE_MODE = "GPSMeasureMode"
6094```
6095
6096**Description**
6097
6098GPS measurement pmode.
6099
6100**Since**: 12
6101
6102
6103### OHOS_IMAGE_PROPERTY_GPS_PROCESSING_METHOD
6104
6105```
6106static const char* OHOS_IMAGE_PROPERTY_GPS_PROCESSING_METHOD = "GPSProcessingMethod"
6107```
6108
6109**Description**
6110
6111String that records the name of the method used for positioning.
6112
6113**Since**: 12
6114
6115
6116### OHOS_IMAGE_PROPERTY_GPS_SATELLITES
6117
6118```
6119static const char* OHOS_IMAGE_PROPERTY_GPS_SATELLITES = "GPSSatellites"
6120```
6121
6122**Description**
6123
6124GPS satellites used for measurement.
6125
6126**Since**: 12
6127
6128
6129### OHOS_IMAGE_PROPERTY_GPS_SPEED
6130
6131```
6132static const char* OHOS_IMAGE_PROPERTY_GPS_SPEED = "GPSSpeed"
6133```
6134
6135**Description**
6136
6137Movement speed of the GPS receiver.
6138
6139**Since**: 12
6140
6141
6142### OHOS_IMAGE_PROPERTY_GPS_SPEED_REF
6143
6144```
6145static const char* OHOS_IMAGE_PROPERTY_GPS_SPEED_REF = "GPSSpeedRef"
6146```
6147
6148**Description**
6149
6150Unit used to express the movement speed of the GPS receiver.
6151
6152**Since**: 12
6153
6154
6155### OHOS_IMAGE_PROPERTY_GPS_STATUS
6156
6157```
6158static const char* OHOS_IMAGE_PROPERTY_GPS_STATUS = "GPSStatus"
6159```
6160
6161**Description**
6162
6163Status of the GPS receiver when the image was recorded.
6164
6165**Since**: 12
6166
6167
6168### OHOS_IMAGE_PROPERTY_GPS_TRACK
6169
6170```
6171static const char* OHOS_IMAGE_PROPERTY_GPS_TRACK = "GPSTrack"
6172```
6173
6174**Description**
6175
6176Movement direction of the GPS receiver.
6177
6178**Since**: 12
6179
6180
6181### OHOS_IMAGE_PROPERTY_GPS_TRACK_REF
6182
6183```
6184static const char* OHOS_IMAGE_PROPERTY_GPS_TRACK_REF = "GPSTrackRef"
6185```
6186
6187**Description**
6188
6189Reference of the movement direction of the GPS receiver.
6190
6191**Since**: 12
6192
6193
6194### OHOS_IMAGE_PROPERTY_GPS_VERSION_ID
6195
6196```
6197static const char* OHOS_IMAGE_PROPERTY_GPS_VERSION_ID = "GPSVersionID"
6198```
6199
6200**Description**
6201
6202Version of GPSInfoIFD.
6203
6204**Since**: 12
6205
6206
6207### OHOS_IMAGE_PROPERTY_IMAGE_LENGTH
6208
6209```
6210static const char* OHOS_IMAGE_PROPERTY_IMAGE_LENGTH = "ImageLength"
6211```
6212
6213**Description**
6214
6215Image length.
6216
6217**Since**: 12
6218
6219
6220### OHOS_IMAGE_PROPERTY_IMAGE_UNIQUE_ID
6221
6222```
6223static const char* OHOS_IMAGE_PROPERTY_IMAGE_UNIQUE_ID = "ImageUniqueID"
6224```
6225
6226**Description**
6227
6228Unique identifier assigned to each image.
6229
6230**Since**: 12
6231
6232
6233### OHOS_IMAGE_PROPERTY_IMAGE_WIDTH
6234
6235```
6236static const char* OHOS_IMAGE_PROPERTY_IMAGE_WIDTH = "ImageWidth"
6237```
6238
6239**Description**
6240
6241Image width.
6242
6243**Since**: 12
6244
6245
6246### OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEYYY
6247
6248```
6249static const char* OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEYYY = "ISOSpeedLatitudeyyy"
6250```
6251
6252**Description**
6253
6254ISO speed latitude yyy value of the camera or input device, which is defined in ISO 12232.
6255
6256**Since**: 12
6257
6258
6259### OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEZZZ
6260
6261```
6262static const char* OHOS_IMAGE_PROPERTY_ISO_SPEED_LATITUDEZZZ = "ISOSpeedLatitudezzz"
6263```
6264
6265**Description**
6266
6267ISO speed latitude zzz value of the camera or input device, which is defined in ISO 12232.
6268
6269**Since**: 12
6270
6271
6272### OHOS_IMAGE_PROPERTY_ISO_SPEED_RATINGS
6273
6274```
6275static const char* OHOS_IMAGE_PROPERTY_ISO_SPEED_RATINGS = "ISOSpeedRatings"
6276```
6277
6278**Description**
6279
6280ISO sensitivity or ISO speed, for example, 400.
6281
6282**Since**: 12
6283
6284
6285### OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT
6286
6287```
6288static const char* OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT = "JPEGInterchangeFormat"
6289```
6290
6291**Description**
6292
6293Offset of the SOI marker of a JPEG interchange format bitstream.
6294
6295**Since**: 12
6296
6297
6298### OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT_LENGTH
6299
6300```
6301static const char* OHOS_IMAGE_PROPERTY_JPEG_INTERCHANGE_FORMAT_LENGTH = "JPEGInterchangeFormatLength"
6302```
6303
6304**Description**
6305
6306Number of bytes of the JPEG stream.
6307
6308**Since**: 12
6309
6310
6311### OHOS_IMAGE_PROPERTY_LENS_MAKE
6312
6313```
6314static const char* OHOS_IMAGE_PROPERTY_LENS_MAKE = "LensMake"
6315```
6316
6317**Description**
6318
6319Manufacturer of the lens.
6320
6321**Since**: 12
6322
6323
6324### OHOS_IMAGE_PROPERTY_LENS_MODEL
6325
6326```
6327static const char* OHOS_IMAGE_PROPERTY_LENS_MODEL = "LensModel"
6328```
6329
6330**Description**
6331
6332Model of the lens.
6333
6334**Since**: 12
6335
6336
6337### OHOS_IMAGE_PROPERTY_LENS_SERIAL_NUMBER
6338
6339```
6340static const char* OHOS_IMAGE_PROPERTY_LENS_SERIAL_NUMBER = "LensSerialNumber"
6341```
6342
6343**Description**
6344
6345Serial number of the lens.
6346
6347**Since**: 12
6348
6349
6350### OHOS_IMAGE_PROPERTY_LENS_SPECIFICATION
6351
6352```
6353static const char* OHOS_IMAGE_PROPERTY_LENS_SPECIFICATION = "LensSpecification"
6354```
6355
6356**Description**
6357
6358Specifications of the lens.
6359
6360**Since**: 12
6361
6362
6363### OHOS_IMAGE_PROPERTY_MAKER_NOTE
6364
6365```
6366static const char* OHOS_IMAGE_PROPERTY_MAKER_NOTE = "MakerNote"
6367```
6368
6369**Description**
6370
6371Marker used by EXIF/DCF manufacturers to record any required information.
6372
6373**Since**: 12
6374
6375
6376### OHOS_IMAGE_PROPERTY_MAX_APERTURE_VALUE
6377
6378```
6379static const char* OHOS_IMAGE_PROPERTY_MAX_APERTURE_VALUE = "MaxApertureValue"
6380```
6381
6382**Description**
6383
6384Smallest F number of the lens.
6385
6386**Since**: 12
6387
6388
6389### OHOS_IMAGE_PROPERTY_NEW_SUBFILE_TYPE
6390
6391```
6392static const char* OHOS_IMAGE_PROPERTY_NEW_SUBFILE_TYPE = "NewSubfileType"
6393```
6394
6395**Description**
6396
6397Data type of a subfile, such as a full-resolution image, a thumbnail, or a part of a multi-frame image. The value is a bit mask. The value 0 indicates a full-resolution image, **1** indicates a thumbnail, and **2** indicates a part of a multi-frame image.
6398
6399**Since**: 12
6400
6401
6402### OHOS_IMAGE_PROPERTY_OECF
6403
6404```
6405static const char* OHOS_IMAGE_PROPERTY_OECF = "OECF"
6406```
6407
6408**Description**
6409
6410Opto-Electric Conversion Function (OECF) specified in ISO 14524.
6411
6412**Since**: 12
6413
6414
6415### OHOS_IMAGE_PROPERTY_OFFSET_TIME
6416
6417```
6418static const char* OHOS_IMAGE_PROPERTY_OFFSET_TIME = "OffsetTime"
6419```
6420
6421**Description**
6422
6423Time with an offset from UTC when the image was captured, in the format of ��HH:MM.
6424
6425**Since**: 12
6426
6427
6428### OHOS_IMAGE_PROPERTY_OFFSET_TIME_DIGITIZED
6429
6430```
6431static const char* OHOS_IMAGE_PROPERTY_OFFSET_TIME_DIGITIZED = "OffsetTimeDigitized"
6432```
6433
6434**Description**
6435
6436Time with an offset from UTC when the image was digitized. It helps to accurately adjust the timestamp.
6437
6438**Since**: 12
6439
6440
6441### OHOS_IMAGE_PROPERTY_OFFSET_TIME_ORIGINAL
6442
6443```
6444static const char* OHOS_IMAGE_PROPERTY_OFFSET_TIME_ORIGINAL = "OffsetTimeOriginal"
6445```
6446
6447**Description**
6448
6449Time with an offset from UTC when the original image was created. It is critical for time-sensitive applications.
6450
6451**Since**: 12
6452
6453
6454### OHOS_IMAGE_PROPERTY_ORIENTATION
6455
6456```
6457static const char* OHOS_IMAGE_PROPERTY_ORIENTATION = "Orientation"
6458```
6459
6460**Description**
6461
6462Image orientation.
6463
6464**Since**: 12
6465
6466
6467### OHOS_IMAGE_PROPERTY_PHOTOGRAPHIC_SENSITIVITY
6468
6469```
6470static const char* OHOS_IMAGE_PROPERTY_PHOTOGRAPHIC_SENSITIVITY = "PhotographicSensitivity"
6471```
6472
6473**Description**
6474
6475Sensitivity of the camera or input device when the image was captured.
6476
6477**Since**: 12
6478
6479
6480### OHOS_IMAGE_PROPERTY_PHOTOMETRIC_INTERPRETATION
6481
6482```
6483static const char* OHOS_IMAGE_PROPERTY_PHOTOMETRIC_INTERPRETATION = "PhotometricInterpretation"
6484```
6485
6486**Description**
6487
6488Color space of the image data, for example, RGB or YCbCr.
6489
6490**Since**: 12
6491
6492
6493### OHOS_IMAGE_PROPERTY_PLANAR_CONFIGURATION
6494
6495```
6496const char* OHOS_IMAGE_PROPERTY_PLANAR_CONFIGURATION = "PlanarConfiguration"
6497```
6498
6499**Description**
6500
6501Storage format of components of each pixel, which can be chunky or planar.
6502
6503**Since**: 12
6504
6505
6506### OHOS_IMAGE_PROPERTY_PRIMARY_CHROMATICITIES
6507
6508```
6509static const char* OHOS_IMAGE_PROPERTY_PRIMARY_CHROMATICITIES = "PrimaryChromaticities"
6510```
6511
6512**Description**
6513
6514Chromaticities of the primaries of the image.
6515
6516**Since**: 12
6517
6518
6519### OHOS_IMAGE_PROPERTY_REFERENCE_BLACK_WHITE
6520
6521```
6522static const char* OHOS_IMAGE_PROPERTY_REFERENCE_BLACK_WHITE = "ReferenceBlackWhite"
6523```
6524
6525**Description**
6526
6527A pair of headroom and footroom image data values (codes) for each pixel component.
6528
6529**Since**: 12
6530
6531
6532### OHOS_IMAGE_PROPERTY_RELATED_SOUND_FILE
6533
6534```
6535static const char* OHOS_IMAGE_PROPERTY_RELATED_SOUND_FILE = "RelatedSoundFile"
6536```
6537
6538**Description**
6539
6540Name of an audio file related to the image data.
6541
6542**Since**: 12
6543
6544
6545### OHOS_IMAGE_PROPERTY_RESOLUTION_UNIT
6546
6547```
6548static const char* OHOS_IMAGE_PROPERTY_RESOLUTION_UNIT = "ResolutionUnit"
6549```
6550
6551**Description**
6552
6553Unit of measurement for XResolution and YResolution.
6554
6555**Since**: 12
6556
6557
6558### OHOS_IMAGE_PROPERTY_ROWS_PER_STRIP
6559
6560```
6561static const char* OHOS_IMAGE_PROPERTY_ROWS_PER_STRIP = "RowsPerStrip"
6562```
6563
6564**Description**
6565
6566Number of rows per strip.
6567
6568**Since**: 12
6569
6570
6571### OHOS_IMAGE_PROPERTY_SAMPLES_PER_PIXEL
6572
6573```
6574static const char* OHOS_IMAGE_PROPERTY_SAMPLES_PER_PIXEL = "SamplesPerPixel"
6575```
6576
6577**Description**
6578
6579Number of components per pixel. The value is **3** for RGB and YCbCr images. The **JPEG** key is used in JPEG compressed data.
6580
6581**Since**: 12
6582
6583
6584### OHOS_IMAGE_PROPERTY_SATURATION
6585
6586```
6587static const char* OHOS_IMAGE_PROPERTY_SATURATION = "Saturation"
6588```
6589
6590**Description**
6591
6592Direction of saturation processing used by the camera.
6593
6594**Since**: 12
6595
6596
6597### OHOS_IMAGE_PROPERTY_SCENE_CAPTURE_TYPE
6598
6599```
6600static const char* OHOS_IMAGE_PROPERTY_SCENE_CAPTURE_TYPE = "SceneCaptureType"
6601```
6602
6603**Description**
6604
6605Type of the scene that was captured.
6606
6607**Since**: 12
6608
6609
6610### OHOS_IMAGE_PROPERTY_SCENE_POINTER
6611
6612```
6613static const char* OHOS_IMAGE_PROPERTY_SCENE_POINTER = "HwMnoteScenePointer"
6614```
6615
6616**Description**
6617
6618Pointer to the scene.
6619
6620**Since**: 12
6621
6622
6623### OHOS_IMAGE_PROPERTY_SCENE_TYPE
6624
6625```
6626static const char* OHOS_IMAGE_PROPERTY_SCENE_TYPE = "SceneType"
6627```
6628
6629**Description**
6630
6631Type of the scene, for example, portrait, scenery, motion, and night.
6632
6633**Since**: 12
6634
6635
6636### OHOS_IMAGE_PROPERTY_SCENE_VERSION
6637
6638```
6639static const char* OHOS_IMAGE_PROPERTY_SCENE_VERSION = "HwMnoteSceneVersion"
6640```
6641
6642**Description**
6643
6644Scene algorithm version.
6645
6646**Since**: 12
6647
6648
6649### OHOS_IMAGE_PROPERTY_SENSING_METHOD
6650
6651```
6652static const char* OHOS_IMAGE_PROPERTY_SENSING_METHOD = "SensingMethod"
6653```
6654
6655**Description**
6656
6657Type of the image sensor on the camera.
6658
6659**Since**: 12
6660
6661
6662### OHOS_IMAGE_PROPERTY_SHARPNESS
6663
6664```
6665static const char* OHOS_IMAGE_PROPERTY_SHARPNESS = "Sharpness"
6666```
6667
6668**Description**
6669
6670Direction of sharpness processing used by the camera.
6671
6672**Since**: 12
6673
6674
6675### OHOS_IMAGE_PROPERTY_SHUTTER_SPEED_VALUE
6676
6677```
6678static const char* OHOS_IMAGE_PROPERTY_SHUTTER_SPEED_VALUE = "ShutterSpeedValue"
6679```
6680
6681**Description**
6682
6683Shutter speed, expressed in Additive System of Photographic Exposure (APEX) values.
6684
6685**Since**: 12
6686
6687
6688### OHOS_IMAGE_PROPERTY_SOFTWARE
6689
6690```
6691static const char* OHOS_IMAGE_PROPERTY_SOFTWARE = "Software"
6692```
6693
6694**Description**
6695
6696Name and version number of the software used to create the image.
6697
6698**Since**: 12
6699
6700
6701### OHOS_IMAGE_PROPERTY_SOURCE_EXPOSURE_TIMES_OF_COMPOSITE_IMAGE
6702
6703```
6704static const char* OHOS_IMAGE_PROPERTY_SOURCE_EXPOSURE_TIMES_OF_COMPOSITE_IMAGE = "SourceExposureTimesOfCompositeImage"
6705```
6706
6707**Description**
6708
6709Exposure time of source images of the composite image.
6710
6711**Since**: 12
6712
6713
6714### OHOS_IMAGE_PROPERTY_SOURCE_IMAGE_NUMBER_OF_COMPOSITE_IMAGE
6715
6716```
6717static const char* OHOS_IMAGE_PROPERTY_SOURCE_IMAGE_NUMBER_OF_COMPOSITE_IMAGE = "SourceImageNumberOfCompositeImage"
6718```
6719
6720**Description**
6721
6722Number of source images of the composite image.
6723
6724**Since**: 12
6725
6726
6727### OHOS_IMAGE_PROPERTY_SPATIAL_FREQUENCY_RESPONSE
6728
6729```
6730static const char* OHOS_IMAGE_PROPERTY_SPATIAL_FREQUENCY_RESPONSE = "SpatialFrequencyResponse"
6731```
6732
6733**Description**
6734
6735Spatial frequency table of the camera or input device.
6736
6737**Since**: 12
6738
6739
6740### OHOS_IMAGE_PROPERTY_SPECTRAL_SENSITIVITY
6741
6742```
6743static const char* OHOS_IMAGE_PROPERTY_SPECTRAL_SENSITIVITY = "SpectralSensitivity"
6744```
6745
6746**Description**
6747
6748Spectral sensitivity of each channel of the camera.
6749
6750**Since**: 12
6751
6752
6753### OHOS_IMAGE_PROPERTY_STRIP_BYTE_COUNTS
6754
6755```
6756static const char* OHOS_IMAGE_PROPERTY_STRIP_BYTE_COUNTS = "StripByteCounts"
6757```
6758
6759**Description**
6760
6761Number of bytes in each strip after compression.
6762
6763**Since**: 12
6764
6765
6766### OHOS_IMAGE_PROPERTY_STRIP_OFFSETS
6767
6768```
6769static const char* OHOS_IMAGE_PROPERTY_STRIP_OFFSETS = "StripOffsets"
6770```
6771
6772**Description**
6773
6774Byte offset of each strip.
6775
6776**Since**: 12
6777
6778
6779### OHOS_IMAGE_PROPERTY_SUBFILE_TYPE
6780
6781```
6782static const char* OHOS_IMAGE_PROPERTY_SUBFILE_TYPE = "SubfileType"
6783```
6784
6785**Description**
6786
6787Type of data contained in this subfile. This tag has been deprecated. Use **NewSubfileType** instead.
6788
6789**Since**: 12
6790
6791
6792### OHOS_IMAGE_PROPERTY_SUBJECT_AREA
6793
6794```
6795static const char* OHOS_IMAGE_PROPERTY_SUBJECT_AREA = "SubjectArea"
6796```
6797
6798**Description**
6799
6800Location and area of the main subject in the entire scene.
6801
6802**Since**: 12
6803
6804
6805### OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE
6806
6807```
6808static const char* OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE = "SubjectDistance"
6809```
6810
6811**Description**
6812
6813Distance to the subject, in meters.
6814
6815**Since**: 12
6816
6817
6818### OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE_RANGE
6819
6820```
6821static const char* OHOS_IMAGE_PROPERTY_SUBJECT_DISTANCE_RANGE = "SubjectDistanceRange"
6822```
6823
6824**Description**
6825
6826Distance to the subject.
6827
6828**Since**: 12
6829
6830
6831### OHOS_IMAGE_PROPERTY_SUBJECT_LOCATION
6832
6833```
6834static const char* OHOS_IMAGE_PROPERTY_SUBJECT_LOCATION = "SubjectLocation"
6835```
6836
6837**Description**
6838
6839Location of the main subject relative to the left edge.
6840
6841**Since**: 12
6842
6843
6844### OHOS_IMAGE_PROPERTY_SUBSEC_TIME
6845
6846```
6847static const char* OHOS_IMAGE_PROPERTY_SUBSEC_TIME = "SubsecTime"
6848```
6849
6850**Description**
6851
6852Tag used to record fractions of seconds for the **DateTime** tag.
6853
6854**Since**: 12
6855
6856
6857### OHOS_IMAGE_PROPERTY_SUBSEC_TIME_DIGITIZED
6858
6859```
6860static const char* OHOS_IMAGE_PROPERTY_SUBSEC_TIME_DIGITIZED = "SubsecTimeDigitized"
6861```
6862
6863**Description**
6864
6865Tag used to record fractions of seconds for the **DateTimeDigitized** tag.
6866
6867**Since**: 12
6868
6869
6870### OHOS_IMAGE_PROPERTY_SUBSEC_TIME_ORIGINAL
6871
6872```
6873static const char* OHOS_IMAGE_PROPERTY_SUBSEC_TIME_ORIGINAL = "SubsecTimeOriginal"
6874```
6875
6876**Description**
6877
6878Tag used to record fractions of seconds for the **DateTimeOriginal** tag.
6879
6880**Since**: 12
6881
6882
6883### OHOS_IMAGE_PROPERTY_TRANSFER_FUNCTION
6884
6885```
6886static const char* OHOS_IMAGE_PROPERTY_TRANSFER_FUNCTION = "TransferFunction"
6887```
6888
6889**Description**
6890
6891Transfer function for the image, which is usually used for color correction.
6892
6893**Since**: 12
6894
6895
6896### OHOS_IMAGE_PROPERTY_WHITE_POINT
6897
6898```
6899static const char* OHOS_IMAGE_PROPERTY_WHITE_POINT = "WhitePoint"
6900```
6901
6902**Description**
6903
6904Chromaticity of the white point of the image.
6905
6906**Since**: 12
6907
6908
6909### OHOS_IMAGE_PROPERTY_X_IN_ORIGINAL
6910
6911```
6912static const char *OHOS_IMAGE_PROPERTY_X_IN_ORIGINAL = "XInOriginal"
6913```
6914
6915**Description**
6916
6917X coordinate of the upper left corner of the fragment map in the original image.
6918
6919**Since**: 13
6920
6921
6922### OHOS_IMAGE_PROPERTY_X_RESOLUTION
6923
6924```
6925static const char* OHOS_IMAGE_PROPERTY_X_RESOLUTION = "XResolution"
6926```
6927
6928**Description**
6929
6930Number of pixels per ResolutionUnit in the image width (X) direction.
6931
6932**Since**: 12
6933
6934
6935### OHOS_IMAGE_PROPERTY_Y_IN_ORIGINAL
6936
6937```
6938static const char *OHOS_IMAGE_PROPERTY_Y_IN_ORIGINAL = "YInOriginal"
6939```
6940
6941**Description**
6942
6943Y coordinate of the upper left corner of the fragment map in the original image.
6944
6945**Since**: 13
6946
6947
6948### OHOS_IMAGE_PROPERTY_Y_RESOLUTION
6949
6950```
6951static const char* OHOS_IMAGE_PROPERTY_Y_RESOLUTION = "YResolution"
6952```
6953
6954**Description**
6955
6956Number of pixels per ResolutionUnit in the image height (Y) direction.
6957
6958**Since**: 12
6959
6960
6961### OHOS_IMAGE_PROPERTY_YCBCR_COEFFICIENTS
6962
6963```
6964static const char* OHOS_IMAGE_PROPERTY_YCBCR_COEFFICIENTS = "YCbCrCoefficients"
6965```
6966
6967**Description**
6968
6969Transformation from RGB to YCbCr image data.
6970
6971**Since**: 12
6972
6973
6974### OHOS_IMAGE_PROPERTY_YCBCR_POSITIONING
6975
6976```
6977static const char* OHOS_IMAGE_PROPERTY_YCBCR_POSITIONING = "YCbCrPositioning"
6978```
6979
6980**Description**
6981
6982Positioning of subsampled chrominance components relative to luminance samples.
6983
6984**Since**: 12
6985
6986
6987### OHOS_IMAGE_PROPERTY_YCBCR_SUB_SAMPLING
6988
6989```
6990static const char* OHOS_IMAGE_PROPERTY_YCBCR_SUB_SAMPLING = "YCbCrSubSampling"
6991```
6992
6993**Description**
6994
6995Subsampling factors used for the chrominance components of a YCbCr image.
6996
6997**Since**: 12
6998