harmony 鸿蒙preview_output.h

2025-06-12 浏览 (1)

preview_output.h

Overview

The preview_output.h file declares the preview output concepts.

Library: libohcamera.so

File to include: <ohcamera/preview_output.h>

System capability: SystemCapability.Multimedia.Camera.Core

Since: 11

Related module: OH_Camera

Summary

Structs

NameDescription
struct PreviewOutput_CallbacksDescribes the callbacks related to preview output.

Types

NameDescription
typedef struct Camera_PreviewOutput Camera_PreviewOutputDefines a struct for the preview output object.
typedef void(* OH_PreviewOutput_OnFrameStart) (Camera_PreviewOutput *previewOutput)Defines the callback defined in the PreviewOutput_Callbacks struct and used to report preview output frame start events.
typedef void(* OH_PreviewOutput_OnFrameEnd) (Camera_PreviewOutput *previewOutput, int32_t frameCount)Defines the callback defined in the PreviewOutput_Callbacks struct and used to report preview output frame end events.
typedef void(* OH_PreviewOutput_OnError) (Camera_PreviewOutput *previewOutput, Camera_ErrorCode errorCode)Defines the callback defined in the PreviewOutput_Callbacks struct and used to report preview output errors.
typedef struct PreviewOutput_Callbacks PreviewOutput_CallbacksDefines a struct for the callbacks related to preview output.

Functions

NameDescription
Camera_ErrorCode OH_PreviewOutput_RegisterCallback (Camera_PreviewOutput *previewOutput, PreviewOutput_Callbacks *callback)Registers a callback to listen for preview output events.
Camera_ErrorCode OH_PreviewOutput_UnregisterCallback (Camera_PreviewOutput *previewOutput, PreviewOutput_Callbacks *callback)Unregisters the callback used to listen for preview output events.
Camera_ErrorCode OH_PreviewOutput_Start (Camera_PreviewOutput *previewOutput)Starts preview output.
Camera_ErrorCode OH_PreviewOutput_Stop (Camera_PreviewOutput *previewOutput)Stops preview output.
Camera_ErrorCode OH_PreviewOutput_Release (Camera_PreviewOutput *previewOutput)Releases a PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_GetActiveProfile (Camera_PreviewOutput *previewOutput, Camera_Profile **profile)Obtains the profile of a PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_DeleteProfile (Camera_Profile *profile)Deletes the profile of this PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_GetSupportedFrameRates (Camera_PreviewOutput *previewOutput, Camera_FrameRateRange **frameRateRange, uint32_t *size)Obtains the list of frame rates supported by a PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_DeleteFrameRates (Camera_PreviewOutput *previewOutput, Camera_FrameRateRange *frameRateRange)Deletes the frame rate list.
Camera_ErrorCode OH_PreviewOutput_SetFrameRate (Camera_PreviewOutput *previewOutput, int32_t minFps, int32_t maxFps)Sets the frame rates for a PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_GetActiveFrameRate (Camera_PreviewOutput *previewOutput, Camera_FrameRateRange *frameRateRange)Obtains the active frame rates of a PreviewOutput instance.
Camera_ErrorCode OH_PreviewOutput_GetPreviewRotation (Camera_PreviewOutput *previewOutput, int displayRotation, Camera_ImageRotation *imageRotation)Obtains the preview rotation angle.
Camera_ErrorCode OH_PreviewOutput_SetPreviewRotation (Camera_PreviewOutput *previewOutput, Camera_ImageRotation *previewRotation, bool isDisplayLocked)Sets the preview rotation angle.

你可能感兴趣的鸿蒙文章

harmony 鸿蒙Camera Kit

harmony 鸿蒙Camera_CaptureEndInfo

harmony 鸿蒙Camera_CaptureStartInfo

harmony 鸿蒙Camera_ConcurrentInfo

harmony 鸿蒙Camera_Device

harmony 鸿蒙Camera_FrameRateRange

harmony 鸿蒙Camera_FrameShutterEndInfo

harmony 鸿蒙Camera_FrameShutterInfo

harmony 鸿蒙Camera_Location

harmony 鸿蒙Camera_MetadataObject

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