Available on crate feature
native_buffer only.Expand description
Native Buffer bindings
The native buffer module provides APIs that you can use to apply for, use, and release the shared memory, and query memory properties. The following scenario is common for native buffer development: Use the native buffer APIs to create an OH_NativeBuffer instance, obtain memory properties, and map the corresponding ION memory to the process address space.
Source:
Structs§
- OH_
Native Buffer - OH_
Native Buffer_ Color Gamut api-12 - Indicates the color gamut of a native buffer.
- OH_
Native Buffer_ Color Space - OH_
Native Buffer_ ColorXY - OH_
Native Buffer_ Config - OH_NativeBuffer config.
- OH_
Native Buffer_ Cta861 - OH_
Native Buffer_ Format - Indicates the format of a native buffer.
- OH_
Native Buffer_ Metadata Key - OH_
Native Buffer_ Metadata Type - OH_
Native Buffer_ Plane api-12 - Holds info for a single image plane.
- OH_
Native Buffer_ Planes api-12 - Holds all image planes.
- OH_
Native Buffer_ Smpte2086 - OH_
Native Buffer_ Static Metadata - OH_
Native Buffer_ Transform Type api-12 - Indicates the transform type of a native buffer.
- OH_
Native Buffer_ Usage - Indicates the usage of a native buffer.
Functions§
- OH_
Native ⚠Buffer_ Alloc - Alloc a OH_NativeBuffer that matches the passed BufferRequestConfig.
- OH_
Native ⚠Buffer_ From Native Window Buffer api-12 - Converts an OHNativeWindowBuffer instance to an OH_NativeBuffer.
- OH_
Native ⚠Buffer_ GetColor Space api-12 - Get the color space of the OH_NativeBuffer.
- OH_
Native ⚠Buffer_ GetConfig - Return a config of the OH_NativeBuffer in the passed OHNativeBufferConfig struct.
- OH_
Native ⚠Buffer_ GetMetadata Value api-12 - Set the metadata type of the OH_NativeBuffer.
- OH_
Native ⚠Buffer_ GetSeq Num - Get the systen wide unique sequence number of the OH_NativeBuffer.
- OH_
Native ⚠Buffer_ Map - Provide direct cpu access to the OH_NativeBuffer in the process’s address space.
- OH_
Native ⚠Buffer_ MapPlanes api-12 - Provide direct cpu access to the potentially multi-plannar OH_NativeBuffer in the process’s address space.
- OH_
Native ⚠Buffer_ Reference - Adds the reference count of a OH_NativeBuffer.
- OH_
Native ⚠Buffer_ SetColor Space api-11 - Set the color space of the OH_NativeBuffer.
- OH_
Native ⚠Buffer_ SetMetadata Value api-12 - Set the metadata type of the OH_NativeBuffer.
- OH_
Native ⚠Buffer_ Unmap - Remove direct cpu access ability of the OH_NativeBuffer in the process’s address space.
- OH_
Native ⚠Buffer_ Unreference - Decreases the reference count of a OH_NativeBuffer and, when the reference count reaches 0, destroys this OH_NativeBuffer.