Sunday, October 29, 2017

Developers still can’t test HDR+ through the Pixel Visual Core on Android 8.1

Just a few days back, Google released the first developer preview for Android 8.1 Oreo. The update was supposed to enable a hidden SoC on the device called the Pixel Visual Core. Developed in collaboration with Intel, this chip is dedicated exclusively to image processing. In the official blog post announcing Android 8.1 Developer Preview 1, Google stated that developers could test HDR+ processing through the Pixel Visual Core by enabling a new developer option.

Pixel Visual Core on Android 8.1 for the Google Pixel 2

Simple enough for developers to do, right? The only problem is that there is no such developer option available. Users have confirmed this on both the Google Pixel 2 and its larger counterpart the Pixel 2 XL. This video by Ron Amadeo from Ars Technica shows that the "Camera HAL HDR+" developer option is nowhere to be found:

So why is it hidden from the developer options? It appears that Google accidentally left it in as an option that can only be accessible on debug or engineering builds. Oops. Here's the evidence:

We first found the relevant strings related to the Camera HAL HDR+ option in the Settings APK.

  <string name="camera_hal_hdrplus_switch">Camera HAL HDR+</string>  <string name="camera_hal_hdrplus_toast">To apply Camera HAL HDR+ change, reboot device</string>  

Clearly, it's supposed to be a switch that you can toggle. Once you toggle it, you have to reboot for it to take effect. With the help of XDA Recognized Contributor Quinny899, we found the code responsible for this switch. In particular, this is the code that pertains to why this switch is hidden from user builds of the Android 8.1 developer preview:

Pixel Visual Core Camera HAL HDR+

Google Pixel 2 Camera HAL HDR+ Pixel Visual Core

There are multiple checks in place here before the camera HAL HDR+ option can be enabled. First, it checks against a boolean value called "config_show_camera_hal_hdrplus" which is true by default on the Pixel 2 devices (thus making it fail the first conditional). Then, it checks against a system property called "ro.build.type" and if it does not match "userdebug" or "eng" (strings for debugging or engineering builds) then the Camera HAL HDR+ won't be enabled. Finally, there's also a property value called "persist.camera.hdrplus.enable" which can be set to true to forcefully enable the option, however, there's no way to set this value unless your device is rooted (and there's no root available for the Pixel 2/2 XL yet).

Current user builds of Android 8.1 on the Pixel 2 and Pixel 2 XL fail these checks. That means there is currently no way for developers to actually test HDR+ processing through the Pixel Visual Core, as Google stated in its Android 8.1 release post. This was likely just a mistake from Google, and all it would take is an OTA or new factory images to fix.



from xda-developers http://ift.tt/2gTdUXo
via IFTTT

No comments:

Post a Comment