SlideShare a Scribd company logo
OUTLINE
Android camera API history
What’s new of Camera API 2
HAL 3.2
Titan Camera API 2 situation
Solutions & Hacks
Conclusions
API Lv 21
Camera API 1
Camera API 1(camera)
Camera API 2(camera2)
API Lv ##
Camera API 2
HISTORY
ICS
HAL 1.0
JB 4.2 JB 4.3
HAL 1.0 - 3.1
HAL 3.2
HAL 1.0
HAL 2.0
HAL 3.0
KK
HAL 1.0
HAL 2.0
HAL 3.0
HAL 3.1
L
HISTORY
WHAT’S NEW OF CAMERA API 2?
camera & camera2 are both available to App Developer
BUT - only HAL 3.2 enables all features/properties of camera2
Shim layer
being used to as the Facade layer between new camera2 API
and older HAL 1.0-3.1 by using camera API
WHAT’S NEW OF CAMERA API 2?
WHAT’S NEW OF CAMERA API 2?
WHAT’S NEW OF CAMERA API 2?
much more metadata, and per-frame metadata.
more direct controls on sensor and Post Processing
Synchronisation of setting and captures
Full rate, full-res captures in various formats
Support raw image capturing and saving
Camera API 1 is necessary for legacy applications
WHAT’S NEW OF CAMERA API 2?
WHAT’S NEW OF CAMERA API 2?
HAL 3.2
support vendor tags by camera module HAL
support partial metadata result
enables all features/properties of camera2
Not support stream configurations for still captures
Framework assumes high-res JPEG stream can be configured at all
times without showing down preview framerate.
HAL 3.2
HAL 3.2
FULL mode
LIMITED mode
HAL 1.0 - 3.1
LEGACY Mode
HAL 3.2
HAL 3.2
HAL 3.2
Step 1
Step 2Step 3
TITAN CAMERA API 2 SITUATION
Step 1
Step 2Step 3
TITAN CAMERA API 2 SITUATION
TITAN CAMERA API 2 SITUATION
CaptureRequest
frame meta
CaptureRequest
frame meta
camera2 HAL 3
CaptureRequest
frame meta
CaptureRequest
frame meta
CaptureRequest
frame meta
CaptureRequest
frame meta
TITAN CAMERA API 2 SITUATION
CaptureRequest
frame meta
CaptureRequest
frame meta
camera2 HAL 1
CaptureRequest
frame meta
CaptureRequest
frame meta
SHIM
CaptureRequest
frame meta
CaptureRequest
frame meta
TITAN CAMERA API 2 SITUATION
Arcsoft involved to use camera2 only for its camera app.
QCT never supportYUV sensor with HAL 3, and Titan’s camera
solution was forced to use HAL 1.
Vertu decide to use HAL 1 + shim + camera 2 in Apr 2015
Vertu would like to have a Legacy+ device.
TITAN CAMERA API 2 SITUATION
Arcsoft involved to use camera2 only for its camera app.
QCT never supportYUV sensor with HAL 3, and Titan’s camera
solution was forced to use HAL 1.
Vertu decide to use HAL 1 + shim + camera 2 in Apr 2015
Vertu would like to have aVertu specific Legacy+ mode for Titan
TITAN CAMERA API 2 SITUATION
LEGACY+ mode
slowmo/HFR support
Cont. shot/ZSL/BurstCap support (abandoned byVertu at wk 41)
PICAUTO support
AS HDR support
YUV420 to NV12/21, notYV12 format
TITAN CAMERA API 2 SITUATION
mediaserver
android.hardware.Camera
android.hardware.ca
mera2.*
android.hardware.ca
mera2.legacy.*
CameraService(Native)
App
Camera2 Legacy Mode
SHIM Layer
TITAN CAMERA API 2 SITUATION
CameraDeviceUserShimCameraManager
LegacyCameraDevice
RequestThread
Manager
GLThread
Manager
Capture
Collector
TITAN CAMERA API 2 SITUATION
RequestThread
Manager
GLThread
Manager
LegacyMetadata
Mapper
SurfaceTexture
Render
LegacyRequest
Mapper
LegacyResult
Mapper
LegacyXXX
Mapper
LegacyCameraDevice
SOLUTIONS & HACKS
LegacyMetadataMapper
be used for create camera static characteristic from HAL 1
Legacy+ mode
convert HFR support from HAL 1 to HIGH_SPEED_VIDEO
property and export it to camera characteristic
export AS HDR, PICAUTO to camera characteristic
export scene mode FOOD/BACKLIT to camera characteristic
SOLUTIONS & HACKS
LegacyRequestMapper
be used for mapping camera2 request to parameters for HAL 1
Legacy+ mode
adjust fps and HFR mode from HIGH_SPEED_VIDEO setting
set AS HDR and PICAUTO flag
wrapper and convertVERTU specific scene mode to pass CTS
Cont. shot/ZSL/Burst shot request process
SOLUTIONS & HACKS
LegacyResultMapper
be used for mapping camera2 request to parameters for HAL 1
Legacy+ mode
based on HIGH_SPEED_VIDEO setting, convert correct camera2 result
back.
based on AS HDR and PICAUTO flag, convert correct camera2 result
back.
wrapper and convertVERTU specific scene mode to pass CTS
SOLUTIONS & HACKS
More and more?
camera2 settings are stored in native space and extensions are
supported by vendor tags. (not available for Legacy mode)
We must revise the accessor to native space for extra supported
features with Java space support
camera native framework need to be extended (LegacyXXXMapper)
HAL 1 must be greatly modified for supports of all extra features.
SOLUTIONS & HACKS
More and more?
Performance for shim is really not good
parts of shim are not completed, cause most of all stability
problem
not only HAL 1, but underly QCOM camera system also need
to be customised repetitively
CONCLUSIONS
Shim is just a start, what is the next?
Performance tuning, shim is really not good in performance
Complete the shim, parts of shim are not done by Google, which cause
most of all stability problem
Go to lower layer. Not only HAL 1, but underly QCOM camera system
also need to be customised repetitively
PICAUTO Integration
AS HDR Integration

More Related Content

PDF
Embedded Android : System Development - Part I
ODP
Q4.11: Porting Android to new Platforms
PDF
Embedded Android : System Development - Part IV (Android System Services)
PDF
Embedded Android Workshop with Pie
PPT
Learning AOSP - Android Linux Device Driver
PDF
Embedded Android : System Development - Part III (Audio / Video HAL)
PDF
Embedded Android : System Development - Part II (HAL)
PPT
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)
Embedded Android : System Development - Part I
Q4.11: Porting Android to new Platforms
Embedded Android : System Development - Part IV (Android System Services)
Embedded Android Workshop with Pie
Learning AOSP - Android Linux Device Driver
Embedded Android : System Development - Part III (Audio / Video HAL)
Embedded Android : System Development - Part II (HAL)
"Learning AOSP" - Android Hardware Abstraction Layer (HAL)

What's hot (20)

ODP
Embedded Android : System Development - Part III
PDF
Explore Android Internals
PDF
Design and Concepts of Android Graphics
PDF
Embedded Android : System Development - Part II (Linux device drivers)
PDF
Low Level View of Android System Architecture
PDF
Embedded Android : System Development - Part IV
PPTX
Camera 2.0 in Android 4.2
PDF
Android's Multimedia Framework
PDF
Android Treble: Blessing or Trouble?
PPT
Android Audio System
PDF
Android ipm 20110409
PDF
The Android graphics path, in depth
PDF
Android Binder IPC for Linux
PDF
Android's HIDL: Treble in the HAL
PDF
Accessing Hardware on Android
PPT
Learning AOSP - Android Booting Process
PDF
Android Multimedia Framework
PDF
Using and Customizing the Android Framework / part 4 of Embedded Android Work...
PDF
Android Automotive
PDF
Android Security Internals
Embedded Android : System Development - Part III
Explore Android Internals
Design and Concepts of Android Graphics
Embedded Android : System Development - Part II (Linux device drivers)
Low Level View of Android System Architecture
Embedded Android : System Development - Part IV
Camera 2.0 in Android 4.2
Android's Multimedia Framework
Android Treble: Blessing or Trouble?
Android Audio System
Android ipm 20110409
The Android graphics path, in depth
Android Binder IPC for Linux
Android's HIDL: Treble in the HAL
Accessing Hardware on Android
Learning AOSP - Android Booting Process
Android Multimedia Framework
Using and Customizing the Android Framework / part 4 of Embedded Android Work...
Android Automotive
Android Security Internals
Ad

Viewers also liked (14)

PPTX
Hidden Camera 3 APIs in Android 4.4 (KitKat)
PPTX
Camera2 introdction
PPTX
How to create a camera2
PPTX
Android 5.0 Camera2 APIs
ODP
Android Camera Architecture
PPTX
Introduction of Android Camera1
PDF
PPT
Frame Templates
PPTX
GreenDao Introduction
PPT
Book Launch: The H.264 Advanced Video Compression Standard
PPT
Digital Image Processing
PPT
Android Media player
PDF
Location-Based Services on Android
Hidden Camera 3 APIs in Android 4.4 (KitKat)
Camera2 introdction
How to create a camera2
Android 5.0 Camera2 APIs
Android Camera Architecture
Introduction of Android Camera1
Frame Templates
GreenDao Introduction
Book Launch: The H.264 Advanced Video Compression Standard
Digital Image Processing
Android Media player
Location-Based Services on Android
Ad

Similar to Camera2 API, SHIM, and HAL 3.2 in Android 5.1 (20)

PPTX
Surveon Megapxiel Camera Product Introduction
PDF
AVTECH products 2018
PDF
E instruction hardware compatibility charts
PDF
The Ultimate DJI Mavic 2 FAQ: Top 37 Questions Answered
PPTX
Surveon IP Camera Spec-in Guide
PDF
How To Access Code In Large w/ Vim
PDF
DJI Ronin 2 - Create Your Legacy
PDF
Motorola MotoTRBO Firmware 2.3 Release Notes (November 2013)
PDF
System AIML use in 5G Adv Release System SBA and SBI
PDF
XPDDS18: The Evolution of Virtualization in the Arm Architecture - Julien Gra...
PDF
Camera specifications pq_criteria
PDF
高通芯片最eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee强介绍.pdf
PDF
高通芯片发展eeeeeeeeeeeeeeeeeeeeeeeeeeeee规格.pdf
PPTX
Surveon Megapixel Cameras - Professional Features & Functions
PDF
Datavideo RMC-180 Control Box Brochure
PDF
Datavideo RMC-180 Brochure
DOCX
New microsoft office word document
PDF
hcm381-481_oi.pdf
PPTX
Surveon 3 MP 30 FPS H.264 HDR Camera Series
PDF
Zte utran ur11.1 optional feature description
Surveon Megapxiel Camera Product Introduction
AVTECH products 2018
E instruction hardware compatibility charts
The Ultimate DJI Mavic 2 FAQ: Top 37 Questions Answered
Surveon IP Camera Spec-in Guide
How To Access Code In Large w/ Vim
DJI Ronin 2 - Create Your Legacy
Motorola MotoTRBO Firmware 2.3 Release Notes (November 2013)
System AIML use in 5G Adv Release System SBA and SBI
XPDDS18: The Evolution of Virtualization in the Arm Architecture - Julien Gra...
Camera specifications pq_criteria
高通芯片最eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee强介绍.pdf
高通芯片发展eeeeeeeeeeeeeeeeeeeeeeeeeeeee规格.pdf
Surveon Megapixel Cameras - Professional Features & Functions
Datavideo RMC-180 Control Box Brochure
Datavideo RMC-180 Brochure
New microsoft office word document
hcm381-481_oi.pdf
Surveon 3 MP 30 FPS H.264 HDR Camera Series
Zte utran ur11.1 optional feature description

Recently uploaded (20)

PDF
Design an Analysis of Algorithms I-SECS-1021-03
PDF
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PPTX
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
PDF
System and Network Administraation Chapter 3
PPTX
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
PDF
Understanding Forklifts - TECH EHS Solution
PDF
Adobe Illustrator 28.6 Crack My Vision of Vector Design
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
PDF
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
PDF
AI in Product Development-omnex systems
PDF
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
PDF
top salesforce developer skills in 2025.pdf
PDF
Design an Analysis of Algorithms II-SECS-1021-03
PDF
Nekopoi APK 2025 free lastest update
PDF
Softaken Excel to vCard Converter Software.pdf
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PPTX
Introduction to Artificial Intelligence
PPTX
Operating system designcfffgfgggggggvggggggggg
Design an Analysis of Algorithms I-SECS-1021-03
Adobe Premiere Pro 2025 (v24.5.0.057) Crack free
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
Oracle E-Business Suite: A Comprehensive Guide for Modern Enterprises
System and Network Administraation Chapter 3
Lecture 3: Operating Systems Introduction to Computer Hardware Systems
Understanding Forklifts - TECH EHS Solution
Adobe Illustrator 28.6 Crack My Vision of Vector Design
How to Migrate SBCGlobal Email to Yahoo Easily
Flood Susceptibility Mapping Using Image-Based 2D-CNN Deep Learnin. Overview ...
AI in Product Development-omnex systems
Raksha Bandhan Grocery Pricing Trends in India 2025.pdf
top salesforce developer skills in 2025.pdf
Design an Analysis of Algorithms II-SECS-1021-03
Nekopoi APK 2025 free lastest update
Softaken Excel to vCard Converter Software.pdf
Wondershare Filmora 15 Crack With Activation Key [2025
Internet Downloader Manager (IDM) Crack 6.42 Build 41
Introduction to Artificial Intelligence
Operating system designcfffgfgggggggvggggggggg

Camera2 API, SHIM, and HAL 3.2 in Android 5.1

  • 1. OUTLINE Android camera API history What’s new of Camera API 2 HAL 3.2 Titan Camera API 2 situation Solutions & Hacks Conclusions
  • 2. API Lv 21 Camera API 1 Camera API 1(camera) Camera API 2(camera2) API Lv ## Camera API 2 HISTORY
  • 3. ICS HAL 1.0 JB 4.2 JB 4.3 HAL 1.0 - 3.1 HAL 3.2 HAL 1.0 HAL 2.0 HAL 3.0 KK HAL 1.0 HAL 2.0 HAL 3.0 HAL 3.1 L HISTORY
  • 4. WHAT’S NEW OF CAMERA API 2?
  • 5. camera & camera2 are both available to App Developer BUT - only HAL 3.2 enables all features/properties of camera2 Shim layer being used to as the Facade layer between new camera2 API and older HAL 1.0-3.1 by using camera API WHAT’S NEW OF CAMERA API 2?
  • 6. WHAT’S NEW OF CAMERA API 2?
  • 7. WHAT’S NEW OF CAMERA API 2? much more metadata, and per-frame metadata. more direct controls on sensor and Post Processing Synchronisation of setting and captures Full rate, full-res captures in various formats Support raw image capturing and saving Camera API 1 is necessary for legacy applications
  • 8. WHAT’S NEW OF CAMERA API 2?
  • 9. WHAT’S NEW OF CAMERA API 2?
  • 10. HAL 3.2 support vendor tags by camera module HAL support partial metadata result enables all features/properties of camera2 Not support stream configurations for still captures Framework assumes high-res JPEG stream can be configured at all times without showing down preview framerate.
  • 11. HAL 3.2 HAL 3.2 FULL mode LIMITED mode HAL 1.0 - 3.1 LEGACY Mode
  • 15. Step 1 Step 2Step 3 TITAN CAMERA API 2 SITUATION
  • 16. Step 1 Step 2Step 3 TITAN CAMERA API 2 SITUATION
  • 17. TITAN CAMERA API 2 SITUATION CaptureRequest frame meta CaptureRequest frame meta camera2 HAL 3 CaptureRequest frame meta CaptureRequest frame meta CaptureRequest frame meta CaptureRequest frame meta
  • 18. TITAN CAMERA API 2 SITUATION CaptureRequest frame meta CaptureRequest frame meta camera2 HAL 1 CaptureRequest frame meta CaptureRequest frame meta SHIM CaptureRequest frame meta CaptureRequest frame meta
  • 19. TITAN CAMERA API 2 SITUATION Arcsoft involved to use camera2 only for its camera app. QCT never supportYUV sensor with HAL 3, and Titan’s camera solution was forced to use HAL 1. Vertu decide to use HAL 1 + shim + camera 2 in Apr 2015 Vertu would like to have a Legacy+ device.
  • 20. TITAN CAMERA API 2 SITUATION Arcsoft involved to use camera2 only for its camera app. QCT never supportYUV sensor with HAL 3, and Titan’s camera solution was forced to use HAL 1. Vertu decide to use HAL 1 + shim + camera 2 in Apr 2015 Vertu would like to have aVertu specific Legacy+ mode for Titan
  • 21. TITAN CAMERA API 2 SITUATION LEGACY+ mode slowmo/HFR support Cont. shot/ZSL/BurstCap support (abandoned byVertu at wk 41) PICAUTO support AS HDR support YUV420 to NV12/21, notYV12 format
  • 22. TITAN CAMERA API 2 SITUATION mediaserver android.hardware.Camera android.hardware.ca mera2.* android.hardware.ca mera2.legacy.* CameraService(Native) App Camera2 Legacy Mode SHIM Layer
  • 23. TITAN CAMERA API 2 SITUATION CameraDeviceUserShimCameraManager LegacyCameraDevice RequestThread Manager GLThread Manager Capture Collector
  • 24. TITAN CAMERA API 2 SITUATION RequestThread Manager GLThread Manager LegacyMetadata Mapper SurfaceTexture Render LegacyRequest Mapper LegacyResult Mapper LegacyXXX Mapper LegacyCameraDevice
  • 25. SOLUTIONS & HACKS LegacyMetadataMapper be used for create camera static characteristic from HAL 1 Legacy+ mode convert HFR support from HAL 1 to HIGH_SPEED_VIDEO property and export it to camera characteristic export AS HDR, PICAUTO to camera characteristic export scene mode FOOD/BACKLIT to camera characteristic
  • 26. SOLUTIONS & HACKS LegacyRequestMapper be used for mapping camera2 request to parameters for HAL 1 Legacy+ mode adjust fps and HFR mode from HIGH_SPEED_VIDEO setting set AS HDR and PICAUTO flag wrapper and convertVERTU specific scene mode to pass CTS Cont. shot/ZSL/Burst shot request process
  • 27. SOLUTIONS & HACKS LegacyResultMapper be used for mapping camera2 request to parameters for HAL 1 Legacy+ mode based on HIGH_SPEED_VIDEO setting, convert correct camera2 result back. based on AS HDR and PICAUTO flag, convert correct camera2 result back. wrapper and convertVERTU specific scene mode to pass CTS
  • 28. SOLUTIONS & HACKS More and more? camera2 settings are stored in native space and extensions are supported by vendor tags. (not available for Legacy mode) We must revise the accessor to native space for extra supported features with Java space support camera native framework need to be extended (LegacyXXXMapper) HAL 1 must be greatly modified for supports of all extra features.
  • 29. SOLUTIONS & HACKS More and more? Performance for shim is really not good parts of shim are not completed, cause most of all stability problem not only HAL 1, but underly QCOM camera system also need to be customised repetitively
  • 30. CONCLUSIONS Shim is just a start, what is the next? Performance tuning, shim is really not good in performance Complete the shim, parts of shim are not done by Google, which cause most of all stability problem Go to lower layer. Not only HAL 1, but underly QCOM camera system also need to be customised repetitively PICAUTO Integration AS HDR Integration