MTK 多帧拍照流程分析

771f65d2098542c9d50100b87b2d6978.gif

和你一起终身学习,这里是程序员Android

经典好文推荐,通过阅读本文,您将收获以下知识点:

一、多帧拍照请求概览
二、多帧拍照回帧概览

一、多帧拍照请求概览

多帧拍照请求概览如下:

5e77fe942101ad2fd9081dab02827288.png
多帧拍照请求
1.1 APP 下发拍照请求到 Camera Framework
1.1.1 Trace关键字如下:

APP:
deliverInputEvent: app 点击事件处理
CameraUnitCamera2ImplTakePicture: app 下发拍照请求
binder transaction :通过bind 跟FWK交互

FWK:
binder reply :响应app 下发的bind
submitRequestList:Camera FWK提交拍照请求给HAL,并包含拍照帧数
captureList
submitRequestsHelper
createCaptureRequest :比如多帧会下发4 帧
queueRequestList
unpauseForNewRequests:暂停新的拍照请求

1.1.2 详细请看下面trace 截图
de046e1d392cb48670792df2e78e77da.png
1.1.3 下发4帧请求createCaptureRequest
b1e23f36513ab49a2a340f2fc2c803db.png
请求4帧
1.2 Camera Framework下发拍照请求到 camera HAL中
1.2.1 Trace关键字如下:

FWK:
sendRequestsBatch:Camera FWK 下发批处理请求
CameraHal::processBatchCaptureRequests: Camera FWK 每帧请求到HAL
HIDL::ICameraDeviceSession::processCaptureRequest_3_4::client: Camera 向Camera HAL请求一帧
binder transaction

CAM HAL:
binder reply
HIDL::ICameraDeviceSession::processCaptureRequest_3_4::server :Camera HAL接受处理Camera FWK 请求
processCaptureRequest_3_4
processCaptureRequest
submitOneRequest
onRequest_EvaluateRequest
evaluateRequest
FeatureSettingPolicy::evaluateRequest
evaluateCaptureSetting
negotiate
onRequest_ProcessEvaluatedFrame
processEvaluatedFrame
onProcessEvaluatedFrame
submitZslRequest:Camera HAL 提交拍照请求帧
makePipelineFrame
queue|requestNo:97 frameNo:97
onFrameUpdated

1.2.2 详细请看下面trace 截图
41e00aa8d8fb9d989a96ce18e0ee6f54.png
1.2.3 拍照log关键字:

control.captureIntent:2|capture req#
拍照log 如下:

01-02 09:05:10.695442  1161  1642 I mtkcam-PipelineModelSession: [submitRequest] <Default/1> requestNo:94 { repeating:0 control.aeTargetFpsRange:5,30 control.captureIntent:2 control.enableZsl:1 control.processRawEn:0 control.mode:1 control.sceneMode:0 control.videoStabilizationMode:0 edge.mode:2 }
01-02 09:05:10.695560  1161  1642 I mtkcam-FeatureSettingPolicy: [evaluateCaptureSetting] (0xb4000075a3a43020) capture req#:94
01-02 09:05:10.734815  1161  1642 I mtkcam-PipelineModelSession: [submitRequest] <Default/1> requestNo:95 { repeating:0 control.aeTargetFpsRange:5,30 control.captureIntent:2 control.enableZsl:1 control.processRawEn:0 control.mode:1 control.sceneMode:0 control.videoStabilizationMode:0 edge.mode:2 }
01-02 09:05:10.734937  1161  1642 I mtkcam-FeatureSettingPolicy: [evaluateCaptureSetting] (0xb4000075a3a43020) capture req#:95
01-02 09:05:10.770126  1161  1645 I mtkcam-PipelineModelSession: [submitRequest] <Default/1> requestNo:96 { repeating:0 control.aeTargetFpsRange:5,30 control.captureIntent:2 control.enableZsl:1 control.processRawEn:0 control.mode:1 control.sceneMode:0 control.videoStabilizationMode:0 edge.mode:2 }
01-02 09:05:10.770526  1161  1645 I mtkcam-FeatureSettingPolicy: [evaluateCaptureSetting] (0xb4000075a3a43020) capture req#:96
01-02 09:05:10.795720  1161  1645 I mtkcam-PipelineModelSession: [submitRequest] <Default/1> requestNo:97 { repeating:0 control.aeTargetFpsRange:5,30 control.captureIntent:2 control.enableZsl:1 control.processRawEn:0 control.mode:1 control.sceneMode:0 control.videoStabilizationMode:0 edge.mode:2 }
01-02 09:05:10.795846  1161  1645 I mtkcam-FeatureSettingPolicy: [evaluateCaptureSetting] (0xb4000075a3a43020) capture 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

程序员Android

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值