未验证 提交 695a6806 编写于 作者: O openharmony_ci 提交者: Gitee

!5539 设置surface注意事项

Merge pull request !5539 from hwgaizw/0618
...@@ -45,8 +45,6 @@ VideoPlayer支持的url媒体源输入类型可参考:[url属性说明](../ref ...@@ -45,8 +45,6 @@ VideoPlayer支持的url媒体源输入类型可参考:[url属性说明](../ref
Xcomponent创建方法可参考:[Xcomponent创建方法](https://gitee.com/openharmony/docs/blob/master/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-xcomponent.md) Xcomponent创建方法可参考:[Xcomponent创建方法](https://gitee.com/openharmony/docs/blob/master/zh-cn/application-dev/reference/arkui-ts/ts-basic-components-xcomponent.md)
*注意:SetSurface需要在设置url和Prepare之间
```js ```js
import media from '@ohos.multimedia.media' import media from '@ohos.multimedia.media'
import fileIO from '@ohos.fileio' import fileIO from '@ohos.fileio'
......
...@@ -679,6 +679,8 @@ setDisplaySurface(surfaceId: string, callback: AsyncCallback\<void>): void ...@@ -679,6 +679,8 @@ setDisplaySurface(surfaceId: string, callback: AsyncCallback\<void>): void
通过回调方式设置SurfaceId。 通过回调方式设置SurfaceId。
*注意:SetDisplaySurface需要在设置url和Prepare之间,无音频的视频流必须设置Surface否则Prepare失败。
**系统能力:** SystemCapability.Multimedia.Media.VideoPlayer **系统能力:** SystemCapability.Multimedia.Media.VideoPlayer
**参数:** **参数:**
...@@ -706,6 +708,8 @@ setDisplaySurface(surfaceId: string): Promise\<void> ...@@ -706,6 +708,8 @@ setDisplaySurface(surfaceId: string): Promise\<void>
通过Promise方式设置SurfaceId。 通过Promise方式设置SurfaceId。
*注意:SetDisplaySurface需要在设置url和Prepare之间,无音频的视频流必须设置Surface否则Prepare失败。
**系统能力:** SystemCapability.Multimedia.Media.VideoPlayer **系统能力:** SystemCapability.Multimedia.Media.VideoPlayer
**参数:** **参数:**
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册