Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Docs
提交
74a5b96c
D
Docs
项目概览
OpenHarmony
/
Docs
大约 1 年 前同步成功
通知
159
Star
292
Fork
28
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
Docs
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
74a5b96c
编写于
9月 26, 2022
作者:
Z
zengyawen
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
update window napis
Signed-off-by:
N
zengyawen
<
zengyawen1@huawei.com
>
上级
90805894
变更
8
显示空白变更内容
内联
并排
Showing
8 changed file
with
607 addition
and
109 deletion
+607
-109
zh-cn/application-dev/reference/native-apis/Readme-CN.md
zh-cn/application-dev/reference/native-apis/Readme-CN.md
+4
-0
zh-cn/application-dev/reference/native-apis/_hi_log.md
zh-cn/application-dev/reference/native-apis/_hi_log.md
+7
-7
zh-cn/application-dev/reference/native-apis/_native_window.md
...n/application-dev/reference/native-apis/_native_window.md
+326
-89
zh-cn/application-dev/reference/native-apis/_o_h_ext_data_handle.md
...ication-dev/reference/native-apis/_o_h_ext_data_handle.md
+61
-0
zh-cn/application-dev/reference/native-apis/_o_h_h_d_r_meta_data.md
...ication-dev/reference/native-apis/_o_h_h_d_r_meta_data.md
+48
-0
zh-cn/application-dev/reference/native-apis/_rect.md
zh-cn/application-dev/reference/native-apis/_rect.md
+71
-0
zh-cn/application-dev/reference/native-apis/_region.md
zh-cn/application-dev/reference/native-apis/_region.md
+45
-0
zh-cn/application-dev/reference/native-apis/external__window_8h.md
...lication-dev/reference/native-apis/external__window_8h.md
+45
-13
未找到文件。
zh-cn/application-dev/reference/native-apis/Readme-CN.md
浏览文件 @
74a5b96c
...
...
@@ -39,5 +39,9 @@
-
[
OH_NativeXComponent_MouseEvent_Callback
](
_o_h___native_x_component___mouse_event___callback.md
)
-
[
OH_NativeXComponent_TouchEvent
](
_o_h___native_x_component___touch_event.md
)
-
[
OH_NativeXComponent_TouchPoint
](
_o_h___native_x_component___touch_point.md
)
-
[
OHExtDataHandle
](
_o_h_ext_data_handle.md
)
-
[
OHHDRMetaData
](
_o_h_h_d_r_meta_data.md
)
-
[
OhosPixelMapInfo
](
_ohos_pixel_map_info.md
)
-
[
RawFileDescriptor
](
_raw_file_descriptor.md
)
-
[
Region
](
_region.md
)
-
[
Rect
](
_rect.md
)
zh-cn/application-dev/reference/native-apis/_hi_log.md
浏览文件 @
74a5b96c
...
...
@@ -110,7 +110,7 @@ DEBUG级别写日志,宏封装接口。
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| fmt | 格式化字符串,基于类printf格式的增强,支持隐私参数标识,即在格式字符串每个参数中符号后类型前增加{public}、{private}标识。 |
...
...
@@ -140,7 +140,7 @@ ERROR级别写日志,宏封装接口。
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| fmt | 格式化字符串,基于类printf格式的增强,支持隐私参数标识,即在格式字符串每个参数中符号后类型前增加{public}、{private}标识。 |
...
...
@@ -170,7 +170,7 @@ FATAL级别写日志,宏封装接口。
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| fmt | 格式化字符串,基于类printf格式的增强,支持隐私参数标识,即在格式字符串每个参数中符号后类型前增加{public}、{private}标识。 |
...
...
@@ -200,7 +200,7 @@ INFO级别写日志,宏封装接口。
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| fmt | 格式化字符串,基于类printf格式的增强,支持隐私参数标识,即在格式字符串每个参数中符号后类型前增加{public}、{private}标识。 |
...
...
@@ -230,7 +230,7 @@ WARN级别写日志,宏封装接口。
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| fmt | 格式化字符串,基于类printf格式的增强,支持隐私参数标识,即在格式字符串每个参数中符号后类型前增加{public}、{private}标识。 |
...
...
@@ -324,7 +324,7 @@ bool OH_LOG_IsLoggable (unsigned int domain, const char * tag, LogLevel level )
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| domain | 指定日志业务领域。 |
| tag | 指定日志TAG。 |
...
...
@@ -354,7 +354,7 @@ int OH_LOG_Print (LogType type, LogLevel level, unsigned int domain, const char
**参数:**
|
Name
| 描述 |
|
名称
| 描述 |
| -------- | -------- |
| type | 日志类型,三方应用日志类型为LOG_APP。 |
| level | 日志级别,日志级别包括LOG_DEBUG、LOG_INFO、LOG_WARN、LOG_ERROR、LOG_FATAL。 |
...
...
zh-cn/application-dev/reference/native-apis/_native_window.md
浏览文件 @
74a5b96c
# NativeWindow
提供NativeWindow功能,主要用来和egl对接
提供NativeWindow功能,主要用来和egl对接
。
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**自从:**
...
...
@@ -18,85 +18,199 @@
### 文件
| 文件名称 | 描述 |
| 文件名称 | 描述 |
| -------- | -------- |
|
[
external_window.h
](
external__window_8h.md
)
| 定义获取和使用NativeWindow的相关函数 |
### 结构体
| 结构体名称 | 描述 |
| -------- | -------- |
|
[
Region
](
_region.md
)
| 表示本地窗口NativeWindow需要更新内容的矩形区域(脏区) |
|
[
OHHDRMetaData
](
_o_h_h_d_r_meta_data.md
)
| HDR元数据结构体定义 |
|
[
OHExtDataHandle
](
_o_h_ext_data_handle.md
)
| 扩展数据句柄结构体定义 |
### 类型定义
| 类型定义名称 | 描述 |
| -------- | -------- |
| OHNativeWindow | 提供对NativeWindow的访问功能 |
| OHNativeWindowBuffer | 提供对NativeWindow的访问功能 |
| Region | 表示本地窗口NativeWindow需要更新内容的矩形区域(脏区) |
### 枚举
| 枚举名称 | 描述 |
| -------- | -------- |
|
[
NativeWindowOperation
](
#nativewindowoperation
)
{ SET_BUFFER_GEOMETRY, GET_BUFFER_GEOMETRY, GET_FORMAT, SET_FORMAT, GET_USAGE, SET_USAGE, SET_STRIDE, GET_STRIDE, SET_SWAP_INTERVAL, GET_SWAP_INTERVAL, SET_TIMEOUT, GET_TIMEOUT, SET_COLOR_GAMUT, GET_COLOR_GAMUT, SET_TRANSFORM, GET_TRANSFORM, SET_UI_TIMESTAMP } | OH_NativeWindow_NativeWindowHandleOpt函数中的操作码 |
|
[
OHScalingMode
](
#ohscalingmode
)
{ OH_SCALING_MODE_FREEZE = 0, OH_SCALING_MODE_SCALE_TO_WINDOW, OH_SCALING_MODE_SCALE_CROP, OH_SCALING_MODE_NO_SCALE_CROP } | 缩放模式 Scaling Mode |
|
[
OHHDRMetadataKey
](
#ohhdrmetadatakey
)
{ OH_METAKEY_RED_PRIMARY_X = 0, OH_METAKEY_RED_PRIMARY_Y = 1, OH_METAKEY_GREEN_PRIMARY_X = 2, OH_METAKEY_GREEN_PRIMARY_Y = 3, OH_METAKEY_BLUE_PRIMARY_X = 4, OH_METAKEY_BLUE_PRIMARY_Y = 5, OH_METAKEY_WHITE_PRIMARY_X = 6, OH_METAKEY_WHITE_PRIMARY_Y = 7, OH_METAKEY_MAX_LUMINANCE = 8, OH_METAKEY_MIN_LUMINANCE = 9, OH_METAKEY_MAX_CONTENT_LIGHT_LEVEL = 10, OH_METAKEY_MAX_FRAME_AVERAGE_LIGHT_LEVEL = 11, OH_METAKEY_HDR10_PLUS = 12, OH_METAKEY_HDR_VIVID = 13 } | 枚举HDR元数据关键字 |
### 函数
| 函数名称 | 描述 |
| -------- | -------- |
|
[
OH_NativeWindow_CreateNativeWindowFromSurface
](
#oh_nativewindow_createnativewindowfromsurface
)
(
void
\*
pSurface) | 创建NativeWindow实例,每次调用都会产生一个新的NativeWindow实例 |
|
[
OH_NativeWindow_DestroyNativeWindow
](
#oh_nativewindow_destroynativewindow
)
(
struct
NativeWindow
\*
window) | 将NativeWindow对象的引用计数减1,当引用计数为0的时候,该NativeWindow对象会被析构掉 |
|
[
OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer
](
#oh_nativewindow_createnativewindowbufferfromsurfacebuffer
)
(
void
\*
pSurfaceBuffer) | 创建NativeWindowBuffer实例,每次调用都会产生一个新的NativeWindowBuffer实例 |
|
[
OH_NativeWindow_DestroyNativeWindowBuffer
](
#oh_nativewindow_destroynativewindowbuffer
)
(
struct
NativeWindowBuffer
\*
buffer) | 将NativeWindowBuffer对象的引用计数减1,当引用计数为0的时候,该NativeWindowBuffer对象会被析构掉 |
|
[
OH_NativeWindow_NativeWindowRequestBuffer
](
#oh_nativewindow_nativewindowrequestbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*\*
buffer, int
\*
fenceFd) | 通过NativeWindow对象申请一块NativeWindowBuffer,用以内容生产 |
|
[
OH_NativeWindow_NativeWindowFlushBuffer
](
#oh_nativewindow_nativewindowflushbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*
buffer, int fenceFd, Region region) | 通过NativeWindow将生产好内容的NativeWindowBuffer放回到Buffer队列中,用以内容消费 |
|
[
OH_NativeWindow_NativeWindowCancelBuffer
](
#oh_nativewindow_nativewindowcancelbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*
buffer) | 通过NativeWindow将之前申请出来的NativeWindowBuffer返还到Buffer队列中,供下次再申请 |
|
[
OH_NativeWindow_NativeWindowHandleOpt
](
#oh_nativewindow_nativewindowhandleopt
)
(
struct
NativeWindow
\*
window, int code,...) | 设置/获取NativeWindow的属性,包括设置/获取宽高、内容格式等 |
|
[
OH_NativeWindow_GetBufferHandleFromNative
](
#oh_nativewindow_getbufferhandlefromnative
)
(
struct
NativeWindowBuffer
\*
buffer) | 通过NativeWindowBuffer获取该buffer的BufferHandle指针 |
|
[
OH_NativeWindow_NativeObjectReference
](
#oh_nativewindow_nativeobjectreference
)
(
void
\*
obj) | 增加一个NativeObject的引用计数 |
|
[
OH_NativeWindow_NativeObjectUnreference
](
#oh_nativewindow_nativeobjectunreference
)
(
void
\*
obj) | 减少一个NativeObject的引用计数,当引用计数减少为0时,该NativeObject将被析构掉 |
|
[
OH_NativeWindow_GetNativeObjectMagic
](
#oh_nativewindow_getnativeobjectmagic
)
(
void
\*
obj) | 获取NativeObject的MagicId |
|
[
OH_NativeWindow_CreateNativeWindow
](
#ohnativewindowcreatenativewindow
)
(
void
\*
pSurface) | 创建NativeWindow实例,每次调用都会产生一个新的NativeWindow实例 |
|
[
OH_NativeWindow_DestroyNativeWindow
](
#ohnativewindowdestroynativewindow
)
(
OHNativeWindow
\*
window) | 将NativeWindow对象的引用计数减1,当引用计数为0的时候,该NativeWindow对象会被析构掉 |
|
[
OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer
](
#ohnativewindowcreatenativewindowbufferfromsurfacebuffer
)
(
void
\*
pSurfaceBuffer) | 创建NativeWindowBuffer实例,每次调用都会产生一个新的NativeWindowBuffer实例 |
|
[
OH_NativeWindow_DestroyNativeWindowBuffer
](
#ohnativewindowdestroynativewindowbuffer
)
(
OHNativeWindowBuffer
\*
buffer) | 将NativeWindowBuffer对象的引用计数减1,当引用计数为0的时候,该NativeWindowBuffer对象会被析构掉 |
|
[
OH_NativeWindow_NativeWindowRequestBuffer
](
#ohnativewindownativewindowrequestbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*\*
buffer, int
\*
fenceFd) | 通过NativeWindow对象申请一块NativeWindowBuffer,用以内容生产 |
|
[
OH_NativeWindow_NativeWindowFlushBuffer
](
#ohnativewindownativewindowflushbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*
buffer, int fenceFd,
[
Region
](
_region.md
)
region) | 通过NativeWindow将生产好内容的NativeWindowBuffer放回到Buffer队列中,用以内容消费 |
|
[
OH_NativeWindow_NativeWindowAbortBuffer
](
#ohnativewindownativewindowabortbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*
buffer) | 通过NativeWindow将之前申请出来的NativeWindowBuffer返还到Buffer队列中,供下次再申请 |
|
[
OH_NativeWindow_NativeWindowHandleOpt
](
#ohnativewindownativewindowhandleopt
)
(
OHNativeWindow
\*
window, int code,...) | 设置/获取NativeWindow的属性,包括设置/获取宽高、内容格式等 |
|
[
OH_NativeWindow_GetBufferHandleFromNative
](
#ohnativewindowgetbufferhandlefromnative
)
(
OHNativeWindowBuffer
\*
buffer) | 通过NativeWindowBuffer获取该buffer的BufferHandle指针 |
|
[
OH_NativeWindow_NativeObjectReference
](
#ohnativewindownativeobjectreference
)
(
void
\*
obj) | 增加一个NativeObject的引用计数 |
|
[
OH_NativeWindow_NativeObjectUnreference
](
#ohnativewindownativeobjectunreference
)
(
void
\*
obj) | 减少一个NativeObject的引用计数,当引用计数减少为0时,该NativeObject将被析构掉 |
|
[
OH_NativeWindow_GetNativeObjectMagic
](
#ohnativewindowgetnativeobjectmagic
)
(
void
\*
obj) | 获取NativeObject的MagicId |
|
[
OH_NativeWindow_NativeWindowSetScalingMode
](
#ohnativewindownativewindowsetscalingmode
)
(
OHNativeWindow
\*
window, uint32_t sequence,
[
OHScalingMode
](
#ohscalingmode
)
scalingMode) | 设置NativeWindow的ScalingMode |
|
[
OH_NativeWindow_NativeWindowSetMetaData
](
#ohnativewindownativewindowsetmetadata
)
(
OHNativeWindow
\*
window, uint32_t sequence, int32_t size, const
[
OHHDRMetaData
](
_o_h_h_d_r_meta_data.md
)
\*
metaData) | 设置NativeWindow的元数据 |
|
[
OH_NativeWindow_NativeWindowSetMetaDataSet
](
#ohnativewindownativewindowsetmetadataset
)
(
OHNativeWindow
\*
window, uint32_t sequence,
[
OHHDRMetadataKey
](
#ohhdrmetadatakey
)
key, int32_t size, const uint8_t
\*
metaData) | 设置NativeWindow的元数据集。 |
|
[
OH_NativeWindow_NativeWindowSetTunnelHandle
](
#ohnativewindownativewindowsettunnelhandle
)
(
OHNativeWindow
\*
window, const
[
OHExtDataHandle
](
_o_h_ext_data_handle.md
)
\*
handle) | 设置NativeWindow的TunnelHandle。 |
## 详细描述
## 枚举类型说明
### NativeWindowOperation
```
enum NativeWindowOperation
```
**描述:**
OH_NativeWindow_NativeWindowHandleOpt函数中的操作码
| 枚举值 | 说明 |
| -------- | -------- |
| SET_BUFFER_GEOMETRY | 设置本地窗口缓冲区几何图形, 函数中的可变参数是 [输入] int32_t height,[输入] int32_t width。 |
| GET_BUFFER_GEOMETRY | 获取本地窗口缓冲区几何图形, 函数中的可变参数是 [输出] int32_t
\*
height, [输出] int32_t
\*
width。 |
| GET_FORMAT | 获取本地窗口缓冲区格式, 函数中的可变参数是 [输出] int32_t
\*
format。 |
| SET_FORMAT | 设置本地窗口缓冲区格式, 函数中的可变参数是 [输入] int32_t format。 |
| GET_USAGE | 获取本地窗口缓冲区格式, 函数中的可变参数是 [输出] int32_t
\*
usage。 |
| SET_USAGE | 设置本地窗口缓冲区使用方式, 函数中的可变参数是 [输入] int32_t usage。 |
| SET_STRIDE | 设置本地窗口缓冲区步幅, 函数中的可变参数是 [输入] int32_t stride。 |
| GET_STRIDE | 获取本地窗口缓冲区步幅, 函数中的可变参数是 [输出] int32_t
\*
stride。 |
| SET_SWAP_INTERVAL | 设置本地窗口缓冲区交换间隔, 函数中的可变参数是 [输入] int32_t interval。 |
| GET_SWAP_INTERVAL | 获取本地窗口缓冲区交换间隔, 函数中的可变参数是 [输出] int32_t
\*
interval。 |
| SET_TIMEOUT | 设置请求本地窗口缓冲区的超时等待时间, 函数中的可变参数是 [输入] int32_t timeout。 |
| GET_TIMEOUT | 获取请求本地窗口缓冲区的超时等待时间, 函数中的可变参数是 [输出] int32_t
\*
timeout。 |
| SET_COLOR_GAMUT | 设置本地窗口缓冲区色彩空间, 函数中的可变参数是 [输入] int32_t colorGamut。 |
| GET_COLOR_GAMUT | 获取本地窗口缓冲区色彩空间, 函数中的可变参数是 [out int32_t
\*
colorGamut]。 |
| SET_TRANSFORM | 设置本地窗口缓冲区变换, 函数中的可变参数是 [输入] int32_t transform。 |
| GET_TRANSFORM | 获取本地窗口缓冲区变换, 函数中的可变参数是 [输出] int32_t
\*
transform。 |
| SET_UI_TIMESTAMP | 设置本地窗口缓冲区UI时间戳, 函数中的可变参数是 [输入] uint64_t uiTimestamp。 |
### OHHDRMetadataKey
```
enum OHHDRMetadataKey
```
**描述:**
枚举HDR元数据关键字
| 枚举值 | 描述 |
| -------- | -------- |
| OH_METAKEY_RED_PRIMARY_X | 红基色X坐标 |
| OH_METAKEY_RED_PRIMARY_Y | 红基色Y坐标 |
| OH_METAKEY_GREEN_PRIMARY_X | 绿基色X坐标 |
| OH_METAKEY_GREEN_PRIMARY_Y | 绿基色Y坐标 |
| OH_METAKEY_BLUE_PRIMARY_X | 蓝基色X坐标 |
| OH_METAKEY_BLUE_PRIMARY_Y | 蓝基色Y坐标 |
| OH_METAKEY_WHITE_PRIMARY_X | 白点X坐标 |
| OH_METAKEY_WHITE_PRIMARY_Y | 白点Y坐标 |
| OH_METAKEY_MAX_LUMINANCE | 最大的光亮度 |
| OH_METAKEY_MIN_LUMINANCE | 最小的光亮度 |
| OH_METAKEY_MAX_CONTENT_LIGHT_LEVEL | 最大的内容亮度水平 |
| OH_METAKEY_MAX_FRAME_AVERAGE_LIGHT_LEVEL | 最大的帧平均亮度水平 |
| OH_METAKEY_HDR10_PLUS | HDR10 Plus |
| OH_METAKEY_HDR_VIVID | Vivid |
### OHScalingMode
```
enum OHScalingMode
```
**描述:**
缩放模式 Scaling Mode
| 枚举值 | 描述 |
| -------- | -------- |
| OH_SCALING_MODE_FREEZE | 在接收到窗口大小的缓冲区之前,不可以更新窗口内容 |
| OH_SCALING_MODE_SCALE_TO_WINDOW | 缓冲区在二维中缩放以匹配窗口大小 |
| OH_SCALING_MODE_SCALE_CROP | 缓冲区被统一缩放,使得缓冲区的较小尺寸与窗口大小匹配 |
| OH_SCALING_MODE_NO_SCALE_CROP | 窗口被裁剪为缓冲区裁剪矩形的大小,裁剪矩形之外的像素被视为完全透明 |
## 函数说明
### OH_NativeWindow_CreateNativeWindow
BufferFromSurfaceBuffer
()
### OH_NativeWindow_CreateNativeWindow()
```
struct NativeWindowBuffer* OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer (void * pSurfaceBuffer
)
OHNativeWindow* OH_NativeWindow_CreateNativeWindow (void * pSurface
)
```
**描述:**
创建NativeWindow
Buffer实例,每次调用都会产生一个新的NativeWindowBuffer
实例
创建NativeWindow
实例,每次调用都会产生一个新的NativeWindow
实例
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| pSurface
Buffer | 参数是一个指向生产者buffer的指针,类型为sptr
<
OHOS::SurfaceBuffer
>
|
| pSurface
| 参数是一个指向生产者ProduceSurface的指针,类型为sptr
<
OHOS::Surface
>
|
**返回:**
返回一个指针,指向NativeWindow
Buffer
的结构体实例
返回一个指针,指向NativeWindow的结构体实例
**自从:**
8
### OH_NativeWindow_CreateNativeWindow
FromSurface
()
### OH_NativeWindow_CreateNativeWindow
BufferFromSurfaceBuffer
()
```
struct NativeWindow* OH_NativeWindow_CreateNativeWindowFromSurface (void * pSurface
)
OHNativeWindowBuffer* OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer (void * pSurfaceBuffer
)
```
**描述:**
创建NativeWindow
实例,每次调用都会产生一个新的NativeWindow
实例
创建NativeWindow
Buffer实例,每次调用都会产生一个新的NativeWindowBuffer
实例
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| pSurface
| 参数是一个指向生产者ProduceSurface的指针,类型为sptr
<
OHOS::Surface
>
|
| pSurface
Buffer | 参数是一个指向生产者buffer的指针,类型为sptr
<
OHOS::SurfaceBuffer
>
|
**返回:**
返回一个指针,指向NativeWindow的结构体实例
返回一个指针,指向NativeWindow
Buffer
的结构体实例
**自从:**
...
...
@@ -107,18 +221,18 @@ struct NativeWindow* OH_NativeWindow_CreateNativeWindowFromSurface (void * pSurf
```
void OH_NativeWindow_DestroyNativeWindow (
struct
NativeWindow * window)
void OH_NativeWindow_DestroyNativeWindow (
OH
NativeWindow * window)
```
**描述:**
将NativeWindow对象的引用计数减1,当引用计数为0的时候,该NativeWindow对象会被析构掉
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
...
...
@@ -131,18 +245,18 @@ void OH_NativeWindow_DestroyNativeWindow (struct NativeWindow * window)
```
void OH_NativeWindow_DestroyNativeWindowBuffer (
struct
NativeWindowBuffer * buffer)
void OH_NativeWindow_DestroyNativeWindowBuffer (
OH
NativeWindowBuffer * buffer)
```
**描述:**
将NativeWindowBuffer对象的引用计数减1,当引用计数为0的时候,该NativeWindowBuffer对象会被析构掉
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| buffer | 参数是一个NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -155,18 +269,18 @@ void OH_NativeWindow_DestroyNativeWindowBuffer (struct NativeWindowBuffer * buff
```
BufferHandle* OH_NativeWindow_GetBufferHandleFromNative (
struct
NativeWindowBuffer * buffer)
BufferHandle* OH_NativeWindow_GetBufferHandleFromNative (
OH
NativeWindowBuffer * buffer)
```
**描述:**
通过NativeWindowBuffer获取该buffer的BufferHandle指针
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| buffer | 参数是一个NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -190,11 +304,11 @@ int32_t OH_NativeWindow_GetNativeObjectMagic (void * obj)
获取NativeObject的MagicId
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| obj | 参数是一个NativeWindow or NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -218,11 +332,11 @@ int32_t OH_NativeWindow_NativeObjectReference (void * obj)
增加一个NativeObject的引用计数
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| obj | 参数是一个NativeWindow or NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -246,39 +360,39 @@ int32_t OH_NativeWindow_NativeObjectUnreference (void * obj)
减少一个NativeObject的引用计数,当引用计数减少为0时,该NativeObject将被析构掉
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| obj | 参数是一个NativeWindow or NativeWindowBuffer的结构体实例的指针 |
**返回:**
GSError
GSError
返回值为错误码
**自从:**
8
### OH_NativeWindow_NativeWindow
Cancel
Buffer()
### OH_NativeWindow_NativeWindow
Abort
Buffer()
```
int32_t OH_NativeWindow_NativeWindow
CancelBuffer (struct NativeWindow * window, struct
NativeWindowBuffer * buffer )
int32_t OH_NativeWindow_NativeWindow
AbortBuffer (OHNativeWindow * window, OH
NativeWindowBuffer * buffer )
```
**描述:**
通过NativeWindow将之前申请出来的NativeWindowBuffer返还到Buffer队列中,供下次再申请
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| buffer | 参数是一个NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -296,18 +410,18 @@ GSError 返回值为错误码
```
int32_t OH_NativeWindow_NativeWindowFlushBuffer (
struct NativeWindow * window, struct
NativeWindowBuffer * buffer, int fenceFd, Region region )
int32_t OH_NativeWindow_NativeWindowFlushBuffer (
OHNativeWindow * window, OH
NativeWindowBuffer * buffer, int fenceFd, Region region )
```
**描述:**
通过NativeWindow将生产好内容的NativeWindowBuffer放回到Buffer队列中,用以内容消费
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| buffer | 参数是一个NativeWindowBuffer的结构体实例的指针 |
...
...
@@ -327,21 +441,22 @@ GSError 返回值为错误码
```
int32_t OH_NativeWindow_NativeWindowHandleOpt (
struct
NativeWindow * window, int code, ... )
int32_t OH_NativeWindow_NativeWindowHandleOpt (
OH
NativeWindow * window, int code, ... )
```
**描述:**
设置/获取NativeWindow的属性,包括设置/获取宽高、内容格式等
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| code | 操作码 |
| code | 表示操作码,详见
[
NativeWindowOperation
](
#nativewindowoperation
)
|
| ... | 可变参数,必须与操作码一一对应 |
**返回:**
...
...
@@ -356,18 +471,18 @@ GSError 返回值为错误码
```
int32_t OH_NativeWindow_NativeWindowRequestBuffer (
struct NativeWindow * window, struct
NativeWindowBuffer ** buffer, int * fenceFd )
int32_t OH_NativeWindow_NativeWindowRequestBuffer (
OHNativeWindow * window, OH
NativeWindowBuffer ** buffer, int * fenceFd )
```
**描述:**
通过NativeWindow对象申请一块NativeWindowBuffer,用以内容生产
@syscap SystemCapability.Graphic.Graphic2D.NativeWindow
\
@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| Name | 描述 |
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| buffer | 参数是一个NativeWindowBuffer的结构体实例的二级指针 |
...
...
@@ -380,3 +495,125 @@ GSError 返回值为错误码
**自从:**
8
### OH_NativeWindow_NativeWindowSetMetaData()
```
int32_t OH_NativeWindow_NativeWindowSetMetaData (OHNativeWindow * window, uint32_t sequence, int32_t size, const OHHDRMetaData * metaData )
```
**描述:**
设置NativeWindow的元数据.
\@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| sequence | 生产缓冲区的序列 |
| size | OHHDRMetaData数组的大小 |
| metaDate | 指向OHHDRMetaData数组的指针 |
**返回:**
GSError 返回值为错误码
**自从:**
9
### OH_NativeWindow_NativeWindowSetMetaDataSet()
```
int32_t OH_NativeWindow_NativeWindowSetMetaDataSet (OHNativeWindow * window, uint32_t sequence, OHHDRMetadataKey key, int32_t size, const uint8_t * metaData )
```
**描述:**
设置NativeWindow的元数据集。
\@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针。 |
| sequence | 生产缓冲区的序列。 |
| key | 枚举值OHHDRMetadataKey |
| size | uint8_t向量的大小 |
| metaDate | 指向uint8_t向量的指针 |
**返回:**
GSError 返回值为错误码
**自从:**
9
### OH_NativeWindow_NativeWindowSetScalingMode()
```
int32_t OH_NativeWindow_NativeWindowSetScalingMode (OHNativeWindow * window, uint32_t sequence, OHScalingMode scalingMode )
```
**描述:**
设置NativeWindow的ScalingMode
\@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| sequence | 生产缓冲区的序列 |
| scalingMode | 枚举值OHScalingMode |
**返回:**
GSError 返回值为错误码
**自从:**
9
### OH_NativeWindow_NativeWindowSetTunnelHandle()
```
int32_t OH_NativeWindow_NativeWindowSetTunnelHandle (OHNativeWindow * window, const OHExtDataHandle * handle )
```
**描述:**
设置NativeWindow的TunnelHandle。
\@
syscap SystemCapability.Graphic.Graphic2D.NativeWindow
**参数:**
| 名称 | 描述 |
| -------- | -------- |
| window | 参数是一个NativeWindow的结构体实例的指针 |
| handle | 指向OHExtDataHandle的指针 |
**返回:**
GSError 返回值为错误码
**自从:**
9
zh-cn/application-dev/reference/native-apis/_o_h_ext_data_handle.md
0 → 100644
浏览文件 @
74a5b96c
# OHExtDataHandle
## 概述
扩展数据句柄结构体定义。
**相关模块:**
[
NativeWindow
](
_native_window.md
)
## 汇总
### 成员变量
| 成员变量名称 | 描述 |
| -------- | -------- |
|
[
fd
](
#fd
)
| 句柄 Fd, -1代表不支持 |
|
[
reserveInts
](
#reserveints
)
| Reserve数组的个数 |
|
[
reserve
](
#reserve
)
[
0
]
| Reserve数组 |
## 结构体成员变量说明
### fd
```
int32_t OHExtDataHandle::fd
```
**描述:**
句柄 Fd, -1代表不支持
### reserve
```
int32_t OHExtDataHandle::reserve[0]
```
**描述:**
Reserve数组
### reserveInts
```
uint32_t OHExtDataHandle::reserveInts
```
**描述:**
Reserve数组的个数
zh-cn/application-dev/reference/native-apis/_o_h_h_d_r_meta_data.md
0 → 100644
浏览文件 @
74a5b96c
# OHHDRMetaData
## 概述
扩展数据句柄结构体定义。
**相关模块:**
[
NativeWindow
](
_native_window.md
)
## 汇总
### 成员变量
| 成员变量名称 | 描述 |
| -------- | -------- |
|
[
key
](
#key
)
| HDR元数据关键字 |
|
[
value
](
#value
)
| 关键字对应的值 |
## 结构体成员变量说明
### key
```
OHHDRMetadataKey OHHDRMetaData::key
```
**描述:**
HDR元数据关键字
### value
```
float OHHDRMetaData::value
```
**描述:**
关键字对应的值
zh-cn/application-dev/reference/native-apis/_rect.md
0 → 100644
浏览文件 @
74a5b96c
# Rect
## 概述
矩形区域。
**相关模块:**
[
NativeWindow
](
_native_window.md
)
## 汇总
### 成员变量
| 成员变量名称 | 描述 |
| -------- | -------- |
|
[
x
](
#x
)
| 矩形框起始x坐标。 |
|
[
y
](
#y
)
| 矩形框起始y坐标。 |
|
[
w
](
#w
)
| 矩形框宽度。 |
|
[
h
](
#h
)
| 矩形框高度。 |
### x
```
int32_t Rect::x
```
**描述:**
矩形框起始x坐标。
### y
```
int32_t Rect::y
```
**描述:**
矩形框起始y坐标。
### w
```
uint32_t Rext::w
```
**描述:**
矩形框宽度。
### h
```
uint32_t Rect::h
```
**描述:**
矩形框高度。
zh-cn/application-dev/reference/native-apis/_region.md
0 → 100644
浏览文件 @
74a5b96c
# Region
## 概述
表示本地窗口NativeWindow需要更新内容的矩形区域(脏区)。
**相关模块:**
[
NativeWindow
](
_native_window.md
)
## 汇总
### 成员变量
| 成员变量名称 | 描述 |
| -------- | -------- |
|
[
*rects
](
#rects
)
| 如果rects是空指针nullptr, 默认Buffer大小为脏区。 |
|
[
rectNumber
](
#rectnumber
)
| 如果rectNumber为0,默认Buffer大小为脏区。 |
### rectNumber
```
int32_t Region::rectNumber
```
**描述:**
如果rectNumber为0,默认Buffer大小为脏区。
### \*rects
```
struct Rect Region::*rects
```
**描述:**
结构体指针,类型为
[
Rect
](
_rect.md
)
。如果rects是空指针nullptr, 默认Buffer大小为脏区。
zh-cn/application-dev/reference/native-apis/external__window_8h.md
浏览文件 @
74a5b96c
...
...
@@ -17,19 +17,51 @@
## 汇总
### 结构体
| 结构体名称 | 描述 |
| -------- | -------- |
|
[
Region
](
_region.md
)
| 表示本地窗口NativeWindow需要更新内容的矩形区域(脏区)。 |
|
[
Region::Rect
](
_rect.md
)
| 矩形区域。 |
|
[
OHHDRMetaData
](
_o_h_h_d_r_meta_data.md
)
| HDR元数据结构体定义 。 |
|
[
OHExtDataHandle
](
_o_h_ext_data_handle.md
)
| 扩展数据句柄结构体定义 。 |
### 类型定义
| 类型定义名称 | 描述 |
| -------- | -------- |
| OHNativeWindow | 提供对NativeWindow的访问功能 |
| OHNativeWindowBuffer | 提供对NativeWindowBuffer的访问功能 |
|
[
Region
](
_region.md
)
| 表示本地窗口NativeWindow需要更新内容的矩形区域(脏区) |
### 枚举
| 枚举名称 | 描述 |
| -------- | -------- |
|
[
NativeWindowOperation
](
_native_window.md#nativewindowoperation
)
{ SET_BUFFER_GEOMETRY, GET_BUFFER_GEOMETRY, GET_FORMAT, SET_FORMAT, GET_USAGE, SET_USAGE, SET_STRIDE, GET_STRIDE, SET_SWAP_INTERVAL, GET_SWAP_INTERVAL, SET_TIMEOUT, GET_TIMEOUT, SET_COLOR_GAMUT, GET_COLOR_GAMUT, SET_TRANSFORM, GET_TRANSFORM, SET_UI_TIMESTAMP } | OH_NativeWindow_NativeWindowHandleOpt函数中的操作码 |
|
[
OHScalingMode
](
_native_window.md.#ohscalingmode
)
{ OH_SCALING_MODE_FREEZE = 0, OH_SCALING_MODE_SCALE_TO_WINDOW, OH_SCALING_MODE_SCALE_CROP, OH_SCALING_MODE_NO_SCALE_CROP } | 缩放模式 Scaling Mode |
|
[
OHHDRMetadataKey
](
_native_window.md#ohhdrmetadatakey
)
{ OH_METAKEY_RED_PRIMARY_X = 0, OH_METAKEY_RED_PRIMARY_Y = 1, OH_METAKEY_GREEN_PRIMARY_X = 2, OH_METAKEY_GREEN_PRIMARY_Y = 3, OH_METAKEY_BLUE_PRIMARY_X = 4, OH_METAKEY_BLUE_PRIMARY_Y = 5, OH_METAKEY_WHITE_PRIMARY_X = 6, OH_METAKEY_WHITE_PRIMARY_Y = 7, OH_METAKEY_MAX_LUMINANCE = 8, OH_METAKEY_MIN_LUMINANCE = 9, OH_METAKEY_MAX_CONTENT_LIGHT_LEVEL = 10, OH_METAKEY_MAX_FRAME_AVERAGE_LIGHT_LEVEL = 11, OH_METAKEY_HDR10_PLUS = 12, OH_METAKEY_HDR_VIVID = 13 } | 枚举HDR元数据关键字 |
### 函数
| 函数名称 | 描述 |
| -------- | -------- |
|
[
OH_NativeWindow_CreateNativeWindowFromSurface
](
_native_window.md#oh_nativewindow_createnativewindowfromsurface
)
(
void
\*
pSurface) | 创建NativeWindow实例,每次调用都会产生一个新的NativeWindow实例 |
|
[
OH_NativeWindow_DestroyNativeWindow
](
_native_window.md#oh_nativewindow_destroynativewindow
)
(
struct
NativeWindow
\*
window) | 将NativeWindow对象的引用计数减1,当引用计数为0的时候,该NativeWindow对象会被析构掉 |
|
[
OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer
](
_native_window.md#oh_nativewindow_createnativewindowbufferfromsurfacebuffer
)
(
void
\*
pSurfaceBuffer) | 创建NativeWindowBuffer实例,每次调用都会产生一个新的NativeWindowBuffer实例 |
|
[
OH_NativeWindow_DestroyNativeWindowBuffer
](
_native_window.md#oh_nativewindow_destroynativewindowbuffer
)
(
struct
NativeWindowBuffer
\*
buffer) | 将NativeWindowBuffer对象的引用计数减1,当引用计数为0的时候,该NativeWindowBuffer对象会被析构掉 |
|
[
OH_NativeWindow_NativeWindowRequestBuffer
](
_native_window.md#oh_nativewindow_nativewindowrequestbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*\*
buffer, int
\*
fenceFd) | 通过NativeWindow对象申请一块NativeWindowBuffer,用以内容生产 |
|
[
OH_NativeWindow_NativeWindowFlushBuffer
](
_native_window.md#oh_nativewindow_nativewindowflushbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*
buffer, int fenceFd, Region region) | 通过NativeWindow将生产好内容的NativeWindowBuffer放回到Buffer队列中,用以内容消费 |
|
[
OH_NativeWindow_NativeWindowCancelBuffer
](
_native_window.md#oh_nativewindow_nativewindowcancelbuffer
)
(
struct
NativeWindow
\*
window, struct NativeWindowBuffer
\*
buffer) | 通过NativeWindow将之前申请出来的NativeWindowBuffer返还到Buffer队列中,供下次再申请 |
|
[
OH_NativeWindow_NativeWindowHandleOpt
](
_native_window.md#oh_nativewindow_nativewindowhandleopt
)
(
struct
NativeWindow
\*
window, int code,...) | 设置/获取NativeWindow的属性,包括设置/获取宽高、内容格式等 |
|
[
OH_NativeWindow_GetBufferHandleFromNative
](
_native_window.md#oh_nativewindow_getbufferhandlefromnative
)
(
struct
NativeWindowBuffer
\*
buffer) | 通过NativeWindowBuffer获取该buffer的BufferHandle指针 |
|
[
OH_NativeWindow_NativeObjectReference
](
_native_window.md#oh_nativewindow_nativeobjectreference
)
(
void
\*
obj) | 增加一个NativeObject的引用计数 |
|
[
OH_NativeWindow_NativeObjectUnreference
](
_native_window.md#oh_nativewindow_nativeobjectunreference
)
(
void
\*
obj) | 减少一个NativeObject的引用计数,当引用计数减少为0时,该NativeObject将被析构掉 |
|
[
OH_NativeWindow_GetNativeObjectMagic
](
_native_window.md#oh_nativewindow_getnativeobjectmagic
)
(
void
\*
obj) | 获取NativeObject的MagicId |
|
[
OH_NativeWindow_CreateNativeWindow
](
_native_window.md#ohnativewindowcreatenativewindow
)
(
void
\*
pSurface) | 创建NativeWindow实例,每次调用都会产生一个新的NativeWindow实例 |
|
[
OH_NativeWindow_DestroyNativeWindow
](
_native_window.md#ohnativewindowdestroynativewindow
)
(
OHNativeWindow
\*
window) | 将NativeWindow对象的引用计数减1,当引用计数为0的时候,该NativeWindow对象会被析构掉 |
|
[
OH_NativeWindow_CreateNativeWindowBufferFromSurfaceBuffer
](
_native_window.md#ohnativewindowcreatenativewindowbufferfromsurfacebuffer
)
(
void
\*
pSurfaceBuffer) | 创建NativeWindowBuffer实例,每次调用都会产生一个新的NativeWindowBuffer实例 |
|
[
OH_NativeWindow_DestroyNativeWindowBuffer
](
_native_window.md#ohnativewindowdestroynativewindowbuffer
)
(
OHNativeWindowBuffer
\*
buffer) | 将NativeWindowBuffer对象的引用计数减1,当引用计数为0的时候,该NativeWindowBuffer对象会被析构掉 |
|
[
OH_NativeWindow_NativeWindowRequestBuffer
](
_native_window.md#ohnativewindownativewindowrequestbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*\*
buffer, int
\*
fenceFd) | 通过NativeWindow对象申请一块NativeWindowBuffer,用以内容生产 |
|
[
OH_NativeWindow_NativeWindowFlushBuffer
](
_native_window.md#ohnativewindownativewindowflushbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*
buffer, int fenceFd,
[
Region
](
_region.md
)
region) | 通过NativeWindow将生产好内容的NativeWindowBuffer放回到Buffer队列中,用以内容消费 |
|
[
OH_NativeWindow_NativeWindowAbortBuffer
](
_native_window.md#ohnativewindownativewindowabortbuffer
)
(
OHNativeWindow
\*
window, OHNativeWindowBuffer
\*
buffer) | 通过NativeWindow将之前申请出来的NativeWindowBuffer返还到Buffer队列中,供下次再申请 |
|
[
OH_NativeWindow_NativeWindowHandleOpt
](
_native_window.md#ohnativewindownativewindowhandleopt
)
(
OHNativeWindow
\*
window, int code,...) | 设置/获取NativeWindow的属性,包括设置/获取宽高、内容格式等 |
|
[
OH_NativeWindow_GetBufferHandleFromNative
](
_native_window.md#ohnativewindowgetbufferhandlefromnative
)
(
OHNativeWindowBuffer
\*
buffer) | 通过NativeWindowBuffer获取该buffer的BufferHandle指针 |
|
[
OH_NativeWindow_NativeObjectReference
](
_native_window.md#ohnativewindownativeobjectreference
)
(
void
\*
obj) | 增加一个NativeObject的引用计数 |
|
[
OH_NativeWindow_NativeObjectUnreference
](
_native_window.md#ohnativewindownativeobjectunreference
)
(
void
\*
obj) | 减少一个NativeObject的引用计数,当引用计数减少为0时,该NativeObject将被析构掉 |
|
[
OH_NativeWindow_GetNativeObjectMagic
](
_native_window.md#ohnativewindowgetnativeobjectmagic
)
(
void
\*
obj) | 获取NativeObject的MagicId |
|
[
OH_NativeWindow_NativeWindowSetScalingMode
](
_native_window.md#ohnativewindownativewindowsetscalingmode
)
(
OHNativeWindow
\*
window, uint32_t sequence,
[
OHScalingMode
](
_native_window.md#ohscalingmode
)
scalingMode) | 设置NativeWindow的ScalingMode |
|
[
OH_NativeWindow_NativeWindowSetMetaData
](
_native_window.md#ohnativewindownativewindowsetmetadata
)
(
OHNativeWindow
\*
window, uint32_t sequence, int32_t size, const
[
OHHDRMetaData
](
_o_h_h_d_r_meta_data.md
)
\*
metaData) | 设置NativeWindow的元数据 |
|
[
OH_NativeWindow_NativeWindowSetMetaDataSet
](
_native_window.md#ohnativewindownativewindowsetmetadataset
)
(
OHNativeWindow
\*
window, uint32_t sequence,
[
OHHDRMetadataKey
](
_native_window.md#ohhdrmetadatakey
)
key, int32_t size, const uint8_t
\*
metaData) | 设置NativeWindow的元数据集。 |
|
[
OH_NativeWindow_NativeWindowSetTunnelHandle
](
_native_window.md#ohnativewindownativewindowsettunnelhandle
)
(
OHNativeWindow
\*
window, const
[
OHExtDataHandle
](
_o_h_ext_data_handle.md
)
\*
handle) | 设置NativeWindow的TunnelHandle。 |
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录