未验证 提交 56dccdcc 编写于 作者: O openharmony_ci 提交者: Gitee

!12645 camera文档增加cameraInput open

Merge pull request !12645 from SongChunPeng/master
......@@ -81,6 +81,9 @@ for (let index = 0; index < cameraArray.length; index++) {
// Create a camera input stream.
let cameraInput = await cameraManager.createCameraInput(cameraArray[0])
// Open camera
await cameraInput.open();
// Obtain the output stream capabilities supported by the camera.
let cameraOutputCap = await cameraManager.getSupportedOutputCapability(cameraArray[0]);
if (!cameraOutputCap) {
......
......@@ -81,6 +81,9 @@ for (let index = 0; index < cameraArray.length; index++) {
// 创建相机输入流
let cameraInput = await cameraManager.createCameraInput(cameraArray[0])
// 打开相机
await cameraInput.open();
// 获取相机设备支持的输出流能力
let cameraOutputCap = await cameraManager.getSupportedOutputCapability(cameraArray[0]);
if (!cameraOutputCap) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册