harmony 鸿蒙photo_output.h

2025-06-12 浏览 (2)

photo_output.h

Overview

The photo_output.h file declares the photo output concepts.

Library: libohcamera.so

File to include: <ohcamera/photo_output.h>

System capability: SystemCapability.Multimedia.Camera.Core

Since: 11

Related module: OH_Camera

Summary

Structs

NameDescription
struct PhotoOutput_CallbacksDescribes the callbacks related to photo output.

Types

NameDescription
typedef struct Camera_PhotoOutput Camera_PhotoOutputDefines a struct for the photo output object.
typedef void(* OH_PhotoOutput_OnFrameStart) (Camera_PhotoOutput *photoOutput)Defines the callback defined in the PhotoOutput_Callbacks struct and used to report photo output frame start events.
typedef void(* OH_PhotoOutput_OnFrameShutter) (Camera_PhotoOutput *photoOutput, Camera_FrameShutterInfo *info)Defines the callback defined in the PhotoOutput_Callbacks struct and used to report frame shutter events.
typedef void(* OH_PhotoOutput_OnFrameEnd) (Camera_PhotoOutput *photoOutput, int32_t frameCount)Defines the callback defined in the PhotoOutput_Callbacks struct and used to report photo output frame end events.
typedef void(* OH_PhotoOutput_OnError) (Camera_PhotoOutput *photoOutput, Camera_ErrorCode errorCode)Defines the callback defined in the PhotoOutput_Callbacks struct and used to report photo output errors.
typedef void(* OH_PhotoOutput_CaptureEnd) (Camera_PhotoOutput *photoOutput, int32_t frameCount)Defines the callback invoked when the capture ends.
typedef void(* OH_PhotoOutput_CaptureStartWithInfo) (Camera_PhotoOutput *photoOutput, Camera_CaptureStartInfo *Info)Defines the callback invoked when the capture starts.
typedef void(* OH_PhotoOutput_OnFrameShutterEnd) (Camera_PhotoOutput *photoOutput, Camera_FrameShutterInfo *Info)Defines the callback invoked when frame shutter ends.
typedef void(* OH_PhotoOutput_CaptureReady) (Camera_PhotoOutput *photoOutput)Defines the callback invoked when the camera is ready to take photos. When the callback is received, the next capture can be performed.
typedef void(* OH_PhotoOutput_EstimatedCaptureDuration) (Camera_PhotoOutput *photoOutput, int64_t duration)Defines the callback for the estimated capture duration.
typedef void(* OH_PhotoOutput_PhotoAvailable) (Camera_PhotoOutput *photoOutput, OH_PhotoNative *photo)Defines the callback invoked when a high-resolution photo is available.
typedef void(* OH_PhotoOutput_PhotoAssetAvailable) (Camera_PhotoOutput *photoOutput, OH_MediaAsset *photoAsset)Defines the callback invoked when a photo asset is available.
typedef struct PhotoOutput_Callbacks PhotoOutput_CallbacksDefines a struct for the callbacks related to photo output.

Functions

NameDescription
Camera_ErrorCode OH_PhotoOutput_RegisterCallback (Camera_PhotoOutput *photoOutput, PhotoOutput_Callbacks *callback)Registers a callback to listen for photo output events.
Camera_ErrorCode OH_PhotoOutput_UnregisterCallback (Camera_PhotoOutput *photoOutput, PhotoOutput_Callbacks *callback)Unregisters the callback used to listen for photo output events.
Camera_ErrorCode OH_PhotoOutput_RegisterCaptureStartWithInfoCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureStartWithInfo callback)Registers a callback to listen for capture start events.
Camera_ErrorCode OH_PhotoOutput_UnregisterCaptureStartWithInfoCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureStartWithInfo callback)Unregisters the callback used to listen for capture start events.
Camera_ErrorCode OH_PhotoOutput_RegisterCaptureEndCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureEnd callback)Registers a callback to listen for capture end events.
Camera_ErrorCode OH_PhotoOutput_UnregisterCaptureEndCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureEnd callback)Unregisters the callback used to listen for capture end events.
Camera_ErrorCode OH_PhotoOutput_RegisterFrameShutterEndCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_OnFrameShutterEnd callback)Registers a callback to listen for frame shutter end events.
Camera_ErrorCode OH_PhotoOutput_UnregisterFrameShutterEndCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_OnFrameShutterEnd callback)Unregisters the callback used to listen for frame shutter end events.
Camera_ErrorCode OH_PhotoOutput_RegisterCaptureReadyCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureReady callback)Registers a callback to listen for camera ready events. After the callback is received, the next capture can be performed.
Camera_ErrorCode OH_PhotoOutput_UnregisterCaptureReadyCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_CaptureReady callback)Unregisters the callback used to listen for camera ready events.
Camera_ErrorCode OH_PhotoOutput_RegisterEstimatedCaptureDurationCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_EstimatedCaptureDuration callback)Registers a callback to listen for estimated capture duration events.
Camera_ErrorCode OH_PhotoOutput_UnregisterEstimatedCaptureDurationCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_EstimatedCaptureDuration callback)Unregisters the callback used to listen for estimated capture duration events.
Camera_ErrorCode OH_PhotoOutput_RegisterPhotoAvailableCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_PhotoAvailable callback)Registers a callback to listen for photo availability events.
Camera_ErrorCode OH_PhotoOutput_UnregisterPhotoAvailableCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_PhotoAvailable callback)Unregisters the callback used to listen for photo availability events.
Camera_ErrorCode OH_PhotoOutput_RegisterPhotoAssetAvailableCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_PhotoAssetAvailable callback)Registers a callback to listen for photo asset availability events.
Camera_ErrorCode OH_PhotoOutput_UnregisterPhotoAssetAvailableCallback (Camera_PhotoOutput *photoOutput, OH_PhotoOutput_PhotoAssetAvailable callback)Unregisters the callback used to listen for photo asset availability events.
Camera_ErrorCode OH_PhotoOutput_Capture (Camera_PhotoOutput *photoOutput)Captures a photo.
Camera_ErrorCode OH_PhotoOutput_Capture_WithCaptureSetting (Camera_PhotoOutput *photoOutput, Camera_PhotoCaptureSetting setting)Captures a photo with capture parameters.
Camera_ErrorCode OH_PhotoOutput_Release (Camera_PhotoOutput *photoOutput)Releases a PhotoOutput instance.
Camera_ErrorCode OH_PhotoOutput_IsMirrorSupported (Camera_PhotoOutput *photoOutput, bool *isSupported)Checks whether mirroring is supported.
Camera_ErrorCode OH_PhotoOutput_EnableMirror (Camera_PhotoOutput *photoOutput, bool enabled)Enables dynamic photo capture.
Camera_ErrorCode OH_PhotoOutput_GetActiveProfile (Camera_PhotoOutput *photoOutput, Camera_Profile **profile)Obtains the profile of a PhotoOutput instance.
Camera_ErrorCode OH_PhotoOutput_DeleteProfile (Camera_Profile *profile)Deletes the profile of this PhotoOutput instance.
Camera_ErrorCode OH_PhotoOutput_IsMovingPhotoSupported (Camera_PhotoOutput *photoOutput, bool *isSupported)Checks whether moving photos are supported.
Camera_ErrorCode OH_PhotoOutput_EnableMovingPhoto (Camera_PhotoOutput *photoOutput, bool enabled)Enables moving photos.
Camera_ErrorCode OH_PhotoOutput_GetPhotoRotation (Camera_PhotoOutput *photoOutput, int devicedegree, Camera_ImageRotation *imageRotation)Obtains the photo 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/gxKVE9