openharmony 鸿蒙 capi-image-nativemodule-oh-decodingoptions

2026-08-25 浏览 (1)

OH_DecodingOptions

typedef struct OH_DecodingOptions OH_DecodingOptions

Overview

The OH_DecodingOptions struct describes the decoding options encapsulated at the native layer. The struct is used to set decoding options and is passed in as an input parameter for creating a PixelMap. For details, see OH_ImageSourceNative_CreatePixelmap.

The struct cannot be directly operated. Instead, functions must be called to create and release the struct and operate the fields in the struct.

To create an OH_DecodingOptions object, call OH_DecodingOptions_Create.

To release an OH_DecodingOptions object, call OH_DecodingOptions_Release.

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

Field TypeField NameField DescriptionDefault ValueGetter FunctionSetter Function
int32_tpixelFormatPixel format.RGBA_8888OH_DecodingOptions_GetPixelFormatOH_DecodingOptions_SetPixelFormat
uint32_tindexIndex of the image to decode.0OH_DecodingOptions_GetIndexOH_DecodingOptions_SetIndex
floatrotateRotation angle.0, in degree (deg)OH_DecodingOptions_GetRotateOH_DecodingOptions_SetRotate
Image_SizedesiredSizeDesired output size.Original image sizeOH_DecodingOptions_GetDesiredSizeOH_DecodingOptions_SetDesiredSize
Image_RegiondesiredRegionRegion to decode.Entire imageOH_DecodingOptions_GetDesiredRegionOH_DecodingOptions_SetDesiredRegion
int32_tdesiredDynamicRangeDesired dynamic range.SDROH_DecodingOptions_GetDesiredDynamicRangeOH_DecodingOptions_SetDesiredDynamicRange

Since: 12

Related module: Image_NativeModule

Header file: image_source_native.h

你可能感兴趣的鸿蒙文章

openharmony 鸿蒙 capi-image-nativemodule-oh-pixelmap-hdrmetadatavalue

openharmony 鸿蒙 capi-image-imagepacker-opts-

openharmony 鸿蒙 capi-image-nativemodule-image-region

openharmony 鸿蒙 capi-image-imagepacker-native-

openharmony 鸿蒙 capi-image-imagenative-

openharmony 鸿蒙 capi-image-processing-h

openharmony 鸿蒙 capi-image-ohosimagesourcesupportedformat

openharmony 鸿蒙 capi-image-nativemodule-image-size

openharmony 鸿蒙 capi-image-mdk-h

openharmony 鸿蒙 capi-image-ohosimagesourcedelaytimelist

  • 所属分类: 后端技术
  • 本文标签: 鸿蒙 软件
  • 版权声明: 本文链接 https://seaxiang.com/blog/bAouLlrI