Multi-Camera Support_test_multi_camera_frame_sync-程序员宅基地

技术标签: Android_Camera  Camera  Multi-Camera  Android  

Android 9 introduces API support for multi-camera devices via a new logical camera device composed of two or more physical camera devices pointing in the same direction. The logical camera device is exposed as a single CameraDevice/CaptureSession to an application allowing for interaction with HAL-integrated multi-camera features. Applications can optionally access and control underlying physical camera streams, metadata, and controls.

Multi-camera support

                          Figure 1. Multi-camera support

In this diagram, different camera IDs are color coded. The application can stream raw buffers from each physical camera at the same time. It is also possible to set separate controls and receive separate metadata from different physical cameras.

Examples and sources

Multi-camera devices must be advertised via the logical multi-camera capability.

Camera clients can query the camera ID of the physical devices a particular logical camera is made of by callinggetPhysicalCameraIds(). The IDs returned as part of the result are then used to control physical devices individually via setPhysicalCameraId(). The results from such individual requests can be queried from the complete result by invoking getPhysicalCameraResults().

Individual physical camera requests may support only a limited subset of parameters. To receive a list of the supported parameters, developers can call getAvailablePhysicalCameraRequestKeys().

Physical camera streams are supported only for non-reprocessing requests and only for monochrome and bayer sensors.

Implementation

Support checklist

To add logical multi-camera devices on the HAL side:

For devices running Android 9, camera devices must support replacing one logical YUV/RAW stream with physical streams of the same size (doesn't apply to RAW streams) and the same format from two physical cameras. This doesn't apply to devices running Android 10.

For devices running Android 10 where the camera HAL device version is 3.5 or higher, the camera device must support isStreamCombinationSupported for applications to query whether a particular stream combination containing physical streams is supported.

Stream configuration map

For a logical camera, the mandatory stream combinations for the camera device of a certain hardware level is the same as what's required in CameraDevice.createCaptureSession. All of the streams in the stream configuration map must be logical streams.

For a logical camera device supporting RAW capability with physical sub-cameras of different sizes, if an application configures a logical RAW stream, the logical camera device must not switch to physical sub-cameras with different sensor sizes. This ensures that existing RAW capture applications don't break.

To take advantage of HAL-implemented optical zoom by switching between physical sub-cameras during RAW capture, applications must configure physical sub-camera streams instead of a logical RAW stream.

Guaranteed stream combination

Both the logical camera and its underlying physical cameras must guarantee the mandatory stream combinationsrequired for their device levels.

A logical camera device should operate in the same way as a physical camera device based on its hardware level and capabilities. It's recommended that its feature set is a superset of that of individual physical cameras.

On devices running Android 9, for each guaranteed stream combination, the logical camera must support:

  • 在physical camera支持的情况下,用两个physical camera出两路(分别出一路)size和format相同的physical stream替换一路logical stream (YUV_420_888或RAW).

  • 如果logical camera不支持RAW capability,而底层的physical camera支持,则添加两路raw stream,每个physical camera输出一路。当physical camera具有不同的senso size时,通常会发生这种情况。

  • 使用physical stream代替相同size和format的logical stream。当physical stream和logical stream的minimum_frame_duration相同时,这一定不能减慢Cpature的帧率。

Performance and power considerations

  • Performance:

    • Configuring and streaming physical streams may slow down the logical camera's capture rate due to resource constraints.
    • Applying physical camera settings may slow down the capture rate if the underlying cameras are put into different frame rates.
  • Power:

    • HAL's power optimization continues to work in the default case.
    • Configuring or requesting physical streams may override HAL's internal power optimization and incur more power use.

Customization

You can customize your device implementation in the following ways.

  • Logical_camera_device输出的logical stream完全取决于HAL实现。 如何从底层的physical camera生成并输出的ogic stream对于应用程序和Android Camera Framework是透明的。
  • 对Individual physical requests 和 results 的支持是可选的. 此类请求中的可用参数集也完全取决于特定的HAL实现。
  • 从Android 10开始,HAL可以在调用getCameraIdList将部分或全部PHYSICAL_ID返回,从而减少应用程序可以直接打开的Camera数量。但是,调用getPhysicalCameraCharacteristics 必须返回physical camera的 characteristics。
    /**
     * getCameraIdList:
     *
     * Returns the list of internal camera device interfaces known to this
     * camera provider. These devices can then be accessed via the hardware
     * service manager.
     *
     * External camera devices (camera facing EXTERNAL) must be reported through
     * the device status change callback, not in this list. Only devices with
     * facing BACK or FRONT must be listed here.
     *
     * @return status Status code for the operation, one of:
     *     OK:
     *         On a succesful generation of camera ID list
     *     INTERNAL_ERROR:
     *         A camera ID list cannot be created. This may be due to
     *         a failure to initialize the camera subsystem, for example.
     * @return cameraDeviceServiceNames The vector of internal camera device
     *     names known to this provider.
     */
    getCameraIdList()
            generates (Status status, vec<string> cameraDeviceNames);

 

Validation

Logical multi-camera devices must pass Camera CTS like any other regular camera. The test cases that target this type of device can be found in the LogicalCameraDeviceTest module.

These three ITS tests target multi-camera systems to facilitate the proper fusing of images:

The scene1 and scene4 tests run with the ITS-in-a-box test rig. The test_multi_camera_match test asserts that the brightness of the center of the images match when the two cameras are both enabled. The test_multi_camera_alignment test asserts that camera spacings, orientations, and distortion parameters are properly loaded. If the multi-camera system includes a Wide FoV camera (>90o), the rev2 version of the ITS box is required.

Sensor_fusion is a second test rig that enables repeated, prescribed phone motion and asserts that the gyroscope and image sensor timestamps match and that the multi-camera frames are in sync.

All boxes are available through AcuSpec, Inc. (www.acuspecinc.com, [email protected]) and MYWAY Manufacturing (www.myway.tw, [email protected]). Additionally, the rev1 ITS box can be purchased through West-Mark (www.west-mark.com, [email protected]).

原文地址

        https://source.android.google.cn/devices/camera/multi-camera

版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
本文链接:https://blog.csdn.net/f2006116/article/details/104069870

智能推荐

leetcode 172. 阶乘后的零-程序员宅基地

文章浏览阅读63次。题目给定一个整数 n,返回 n! 结果尾数中零的数量。解题思路每个0都是由2 * 5得来的,相当于要求n!分解成质因子后2 * 5的数目,由于n中2的数目肯定是要大于5的数目,所以我们只需要求出n!中5的数目。C++代码class Solution {public: int trailingZeroes(int n) { ...

Day15-【Java SE进阶】IO流(一):File、IO流概述、File文件对象的创建、字节输入输出流FileInputStream FileoutputStream、释放资源。_outputstream释放-程序员宅基地

文章浏览阅读992次,点赞27次,收藏15次。UTF-8是Unicode字符集的一种编码方案,采取可变长编码方案,共分四个长度区:1个字节,2个字节,3个字节,4个字节。文件字节输入流:每次读取多个字节到字节数组中去,返回读取的字节数量,读取完毕会返回-1。注意1:字符编码时使用的字符集,和解码时使用的字符集必须一致,否则会出现乱码。定义一个与文件一样大的字节数组,一次性读取完文件的全部字节。UTF-8字符集:汉字占3个字节,英文、数字占1个字节。GBK字符集:汉字占2个字节,英文、数字占1个字节。GBK规定:汉字的第一个字节的第一位必须是1。_outputstream释放

jeecgboot重新登录_jeecg 登录自动退出-程序员宅基地

文章浏览阅读1.8k次,点赞3次,收藏3次。解决jeecgboot每次登录进去都会弹出请重新登录问题,在utils文件下找到request.js文件注释这段代码即可_jeecg 登录自动退出

数据中心供配电系统负荷计算实例分析-程序员宅基地

文章浏览阅读3.4k次。我国目前普遍采用需要系数法和二项式系数法确定用电设备的负荷,其中需要系数法是国际上普遍采用的确定计算负荷的方法,最为简便;而二项式系数法在确定设备台数较少且各台设备容量差..._数据中心用电负荷统计变压器

HTML5期末大作业:网页制作代码 网站设计——人电影网站(5页) HTML+CSS+JavaScript 学生DW网页设计作业成品 dreamweaver作业静态HTML网页设计模板_网页设计成品百度网盘-程序员宅基地

文章浏览阅读7k次,点赞4次,收藏46次。HTML5期末大作业:网页制作代码 网站设计——人电影网站(5页) HTML+CSS+JavaScript 学生DW网页设计作业成品 dreamweaver作业静态HTML网页设计模板常见网页设计作业题材有 个人、 美食、 公司、 学校、 旅游、 电商、 宠物、 电器、 茶叶、 家居、 酒店、 舞蹈、 动漫、 明星、 服装、 体育、 化妆品、 物流、 环保、 书籍、 婚纱、 军事、 游戏、 节日、 戒烟、 电影、 摄影、 文化、 家乡、 鲜花、 礼品、 汽车、 其他 等网页设计题目, A+水平作业_网页设计成品百度网盘

【Jailhouse 文章】Look Mum, no VM Exits_jailhouse sr-iov-程序员宅基地

文章浏览阅读392次。jailhouse 文章翻译,Look Mum, no VM Exits!_jailhouse sr-iov

随便推点

chatgpt赋能python:Python怎么删除文件中的某一行_python 删除文件特定几行-程序员宅基地

文章浏览阅读751次。本文由chatgpt生成,文章没有在chatgpt生成的基础上进行任何的修改。以上只是chatgpt能力的冰山一角。作为通用的Aigc大模型,只是展现它原本的实力。对于颠覆工作方式的ChatGPT,应该选择拥抱而不是抗拒,未来属于“会用”AI的人。AI职场汇报智能办公文案写作效率提升教程 专注于AI+职场+办公方向。下图是课程的整体大纲下图是AI职场汇报智能办公文案写作效率提升教程中用到的ai工具。_python 删除文件特定几行

Java过滤特殊字符的正则表达式_java正则表达式过滤特殊字符-程序员宅基地

文章浏览阅读2.1k次。【代码】Java过滤特殊字符的正则表达式。_java正则表达式过滤特殊字符

CSS中设置背景的7个属性及简写background注意点_background设置背景图片-程序员宅基地

文章浏览阅读5.7k次,点赞4次,收藏17次。css中背景的设置至关重要,也是一个难点,因为属性众多,对应的属性值也比较多,这里详细的列举了背景相关的7个属性及对应的属性值,并附上演示代码,后期要用的话,可以随时查看,那我们坐稳开车了······1: background-color 设置背景颜色2:background-image来设置背景图片- 语法:background-image:url(相对路径);-可以同时为一个元素指定背景颜色和背景图片,这样背景颜色将会作为背景图片的底色,一般情况下设置背景..._background设置背景图片

Win10 安装系统跳过创建用户,直接启用 Administrator_windows10msoobe进程-程序员宅基地

文章浏览阅读2.6k次,点赞2次,收藏8次。Win10 安装系统跳过创建用户,直接启用 Administrator_windows10msoobe进程

PyCharm2021安装教程-程序员宅基地

文章浏览阅读10w+次,点赞653次,收藏3k次。Windows安装pycharm教程新的改变功能快捷键合理的创建标题,有助于目录的生成如何改变文本的样式插入链接与图片如何插入一段漂亮的代码片生成一个适合你的列表创建一个表格设定内容居中、居左、居右SmartyPants创建一个自定义列表如何创建一个注脚注释也是必不可少的KaTeX数学公式新的甘特图功能,丰富你的文章UML 图表FLowchart流程图导出与导入导出导入下载安装PyCharm1、进入官网PyCharm的下载地址:http://www.jetbrains.com/pycharm/downl_pycharm2021

《跨境电商——速卖通搜索排名规则解析与SEO技术》一一1.1 初识速卖通的搜索引擎...-程序员宅基地

文章浏览阅读835次。本节书摘来自异步社区出版社《跨境电商——速卖通搜索排名规则解析与SEO技术》一书中的第1章,第1.1节,作者: 冯晓宁,更多章节内容可以访问云栖社区“异步社区”公众号查看。1.1 初识速卖通的搜索引擎1.1.1 初识速卖通搜索作为速卖通卖家都应该知道,速卖通经常被视为“国际版的淘宝”。那么请想一下,普通消费者在淘宝网上购买商品的时候,他的行为应该..._跨境电商 速卖通搜索排名规则解析与seo技术 pdf

推荐文章

热门文章

相关标签