Camera improvements : the state of cameras on sailfish

But can we have that too? That doesn’t seem hard to code.

Although I assume the main improvements would come from merging information from all three cameras in a single HDR picture — and that looks more challenging to code from scratch.

2 Likes

MORE of them: Does this explain why I saw bright displays of Android filming a band in low light conditions and with SFOS X + XA2 the display was dark with a few dots from the spotlights?
API: Do you think the API use can explain that?

1 Like

I don’t think it’s this. You can set lighting boost in the standard SF camera but it doesn’t give results like the Android photo. I’m assuming it’s a post-process boost.

The dark images are getting recorded as low light levels. This indicates a high, fixed shutter speed, either 1/200th or 1/400th of a second. There’s no apparent automatic adjustment/scaling of shutter speed or ISO. If we can influence either, or tell the camera to go auto, this may fix it.

But there may also be problems further down the pipeline. JPEG only has 256 light levels as far as I know. They can’t even be brightened with Photoshop. Even if you can get rid of the graininess, the encoder that sends JPG to the SF apps may be mostly compressing dark levels. and only using around 30.

Now when you take a shot, the camera should be adjusting to the light levels and recording something like 3500-14000 different levels, depending on the hardware. If we had access to the RAW image, we could tell if it’s the camera or the encoder.

Pixel and Galaxy Android camera apps have access to RAW image. not sure about Sony’s. SF doesn’t (yet?).

[Edited to include shutter speed and ISO info.]

2 Likes

Thank you for this detailled explanation @David , i fully agree.

so the question is for me, is there any way to get the full raw data from the Sony blob or are we limited to the reduced 8 bit compressed format forever (maybe by licence agreement or technical limitations from Sony?)?

edit: I think, the controls on the Jolla & also Advanced Camera app is more like a brightness & contrast control of a TV and can’t do anything more. The camera will not become more sensitive if brightness & contrast is increased, the sensor data is always the same, no effect on the ‘real’ sensor settings.

Apparently, shutter speed is a thing. A long exposure lets in more light to the sensor. We’re probably using around a 1/300th of a second speed. If we can occasionaly tell the camera to use a slower speed (or to use auto speed), that may well fix it. It depends what else is screwed up in the pipeline.

Is the Sailfish camera app open? The brightener (certainly isn’t a white balancer) doesn’t seem to me to be a pure brightener either. It may be influencing shutter speed and combining that with brightening.
If it’s not open, and the developer isn’t around, I may be able to do a test of default + Photoshop vs +2 – if the latter produces a better image, it’s using shutter speed. Or maybe ISO. [ISO does nothing on my XA2 on Advanced Camera].

Getting RAW may involve reverse engineering the Sony camera app. I don’t know what the easiest thing to investigate is here.

Updated earlier comment to put all the info in one place.

1 Like

SFOS still makes use of Camera 1 API, which not only didn’t give you RAW, but also basic things like exposure, ISO and shutter speed. Then it is weird SFOS camera even supports some of those. So I think once the system moves to Camera 2 we not only should get all cameras working, but much more access to all possible features. Especially as 10 III supports Level3 API compatibility, so the highest possible access to the camera. And maybe, just maybe the photo quality will simply improve by just this API change, and nothing else? Maybe Sony didn’t implement some features to this deprecated API, and did to new one?

8 Likes

On early Windows-Phone-Mobile-Versions, the Gallery did rework new taken pictures after starting the app i can remember.

1 Like

From what i recall, sony puts decent cameras on their phones and then it’s the camera software doing miracles, the same that disappear if you unlock the bootloader

Someone over the telegram community said to me that developing good camera drivers require more money than everything else , and jolla never had those, and never had the required lab to do it.

Anyway would it be nice if someone could reverse engineer what sony did…

2 Likes

When you buy a Sony Smartphone, its your device right now. So Sony shouldn´t remove Basic Features when the user unlocking the Bootloader. They allowed it (unlocking) - so why they (damage) their Name and Product?

You paid for the Camera-Functionality, too!

5 Likes

Please provide a reference to back up your claim that unlocking the bootloader degrades the camera. People keep repeating this statement over and over, but from what I have been able to find this has not been the case for a long time now. At least since the Xperia XZs got the upgrade to Android 9 Pie, and for any Xperia 10 I/II/III out-of-the-box: https://www.xda-developers.com/sony-xperia-android-pie-unlock-bootloader-drm-fix-camera/

3 Likes

I got my Sony Xperia ZX Premium after unlocking the bootloader (running LineageOS) also fixed this way, see the XDA-Developers link by @d.geelen „…Members tobias.waldvogel, mbc07, munjeni, and others discovered ways to restore the lost functionality by either modifying core system libraries or simulating a locked device without root. Sony likely intended for the DRM-related features to be broken after unlocking the bootloader, but it’s unclear whether the camera taking green pictures is intentional… .” I’m wondering why this shouldn’t be possible in SailfishOS as well.

1 Like

At least we can see in the above pictures that the picture quality in low light is worse under SFOS than under Android.
But that might just be, as said the post treatment which is of lower quality.

That is not post treatment. On SFOS, you get a dark screen/display befor pressing the shutter, not so with Android.

The 10 III already makes really nice looking photos in good ligting conditions. Only problems are when it gets darker. That is why I think it could be the use of Camera API and not Camera 2, because Camera 1 doesn’t allow for control of exposure. And I didn’t see any manual control of exposure either in advanced camera.
If SFOS really is stuck with default exposure I guess that would explain atrocious night performance?

1 Like

Time to test: CameraExposure QML Type | Qt Multimedia 5.15.10

3 Likes

In the cameragallery demo app from jolla, camera dependant controls are exposed:

This works:
camera.exposure.exposureCompensation.toFixed(1)

I wasn’t able to get shutterspeed working on the Vollaphone.

2 Likes

I think ISO / Shutterspeed might be more important? But…

It’s not exposre we’re stuck with but shutterspeed?

I just did a more extreme Sony (10ii) and GS290 comparison and as in my previous tests, the Sony is over saturated and darker. The Voll/GS290 colors are closer to ‘real’ but the camera pushes the exposure compensation more than the sony. All in all, the GS290 takes ‘better’ pictures in low light conditions (and overall for color fidelity). But that’s using the same software. Soooo… time to build a test app that allows you to try to get to a similar compensation level. …

4 Likes

The Xperia X erases its Camera-DSP firmware for de-noising, sharpening, brightening (for low-light conditions) and likely some additional filters / effects, when the bootloader is unlocked. I have no information how newer models handle that, but also no info that this was changed. Still many of the observed effects on newer models can be attributed to that, because they are similar to what the Xperia X shows under Stock-Android before unlocking the bootloader versus SailfishOS, LineageOS etc.

“Easy photos” with high brightness and contrast are fine on the Xperia X without Camera-DSP effects, but in low-light situations the difference is extreme and other, smaller differences can be seen when magnifying critical scenes (e.g., foliage with the sun behind).

I also would be interested to know, if Sony has changed that.

3 Likes

Here for example you can see an Xperia XZ with unlocked bootloader (because it’s rooted, as you can tell from the magisk screen) and yet all the advanced digitally-restriction-managed features are still working: Sony XZ Premium | Android Pie - YouTube

I’m not an Android expert by any means, but from what I can find online the problem here really is with the OS (sailfish) and not the device (sony). It is also acknowledged here and in other threads that a likely cause is that the camera application is just using an old, outdated, no longer supported API (v1) which simply does not offer much advanced functionality (such as exposure, shutter speed, etc), and that using the newer v2 API may be the solution.

I recall a ‘call to arms’ by Jolla around the release of the 10III to work on Camera2 support together with the community, does anyone know the state of that?

6 Likes

I suggested that use of v1 API could be the culprit, but I am not 100% sure it is the actual cause. I can’t wait till we get v2, so we can use all cameras on 10 III as well as get access to more tunables. But we can’t know for sure if it will fix dark performance. So those experiments made by poetaster are super useful to find actual issue.