2017-07-06 41 views
1

現在我們面臨的問題是,帶有黑白傳感器的華爲P9能夠拍攝照片,而不是視頻。我想寫一個快速和骯髒的解決方案,以獲得第二臺相機的工作,但發現,手機只有「2」相機(前/後?!)HUAWEI P9雙攝像頭API(CAM API 2) - Caputre B/W視頻

有誰知道如何訪問黑白傳感器?我知道,CAM API 2沒有雙攝像頭支持(還)。華爲開發者頁面建議使用API​​/SDK,但該按鈕呈灰色。

任何幫助非常感謝!

回答

1

我發現一個已經包含在APP「FreedCam」中的工作。 華爲有一些隱藏的參數:

Regarding P9, it'sinteresting to see, that it shows only two cameras even though it has3. Any idea if the camera API 2 has the ability to use only the black and white sensor? 

com.huawei.device.capabilities.availbaleDualPrimary 
com.huawei.capture.metadata.dualSensorMode 

凸輪1

hw-dual-primary-supported=primary,secondary,dual //primary =color, secondary = mono 
hw-dual-primary-mode=primary 

所以你不能選擇它作爲一個第三相機。

看一看: https://github.com/troop/FreeDcam/blob/42152a8e6b948dc1a05ebb99ecc6fe999c953b1e/app/src/main/java/freed/cam/featuredetector/Camera1FeatureDetectorTask.java