camera.getLivePreview
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
返回分辨率为
选项中的 previewFormat
。
此命令应返回“Content-Type: multipart/x-mixed-Replace;”boundary="---osclivepreview---"".
此命令是在 API 级别 2 中添加的。
参数
结果
错误
- disabledCommand:命令当前已停用;
例如,相机正在拍摄视频。
- invalidParameterName:输入参数名称为
无法识别。
命令 I/O |
命令输入 |
none |
命令输出 |
Continuous video stream. |
命令输出(错误) |
{
"error": {
"code": "disabledCommand",
"message": "Command is currently disabled."
}
} |
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2024-08-21。
[null,null,["最后更新时间 (UTC):2024-08-21。"],[[["\u003cp\u003eInitiates a continuous video stream with the resolution set in previewFormat.\u003c/p\u003e\n"],["\u003cp\u003eReturns a multipart video stream separated by boundary "---osclivepreview---".\u003c/p\u003e\n"],["\u003cp\u003eThis command is only available for API level 2 and above.\u003c/p\u003e\n"],["\u003cp\u003ePotential errors include disabledCommand if the camera is busy and invalidParameterName for incorrect input.\u003c/p\u003e\n"]]],["The command initiates a continuous video stream at the resolution defined by `previewFormat`. The stream is a multipart/x-mixed-replace type, using \"---osclivepreview---\" as a boundary separator. It accepts no parameters. The output is a continuous video stream with frames separated by the boundary. Errors include \"disabledCommand\" (e.g., when the camera is recording) and \"invalidParameterName\". This command was introduced in API level 2.\n"],null,["# camera.getLivePreview\n\nReturns a continuous video stream with the resolution specified by\n`previewFormat` in [Options](/streetview/open-spherical-camera/reference/options).\nThis command should return, \"Content-Type: multipart/x-mixed-replace; boundary=\"---osclivepreview---\"\".\n**This command was added in API level 2.**\n\nParameters\n----------\n\n- This command has no parameter in request body.\n\nResults\n-------\n\n- A continuous video stream with frames separated by the boundary separator.\n\nErrors\n------\n\n- **disabledCommand:** Command is currently disabled; for example, the camera is shooting a video.\n- **invalidParameterName:** The input parameter name is unrecognized.\n\n| Command I/O ----------- ||\n|----------------------------|-----------------------------------------------------------------------------------------------------|\n| **Command Input** | ```text none ``` |\n| **Command Output** | ```text Continuous video stream. ``` |\n| **Command Output (Error)** | ```text { \"error\": { \"code\": \"disabledCommand\", \"message\": \"Command is currently disabled.\" } } ``` |"]]