Conversation

Hey people.

Maybe you heard about my little project.

Which phone should support after ?

I'm looking for one which has the kernel drivers but cameras still don't work great.

7
2
0

@dcz maybe the Pixel 3a? Now supported by multiple distros, relatively modern, and with cameras working but with some hickups as you describe :)

1
0
0

@dcz I'd ask for the Pinephone Pro, though I'd have to confirm kernel drivers for the cameras

The cameras work, but are decidedly not great. Rear camera especially (unless I'm out of date), if only because it can't be used after the phone goes to sleep

1
0
0

@xethos If the issue is sleep, then it's most likely in the kernel, and libobscura won't improve the situation :(

0
0
0

@pabloyoyoista I might actually know where to find one lying around.

Can you tell me what the cameras are missing? Is there like a device page describing problems somewhere?

1
0
0

@dcz unfortunately https://wiki.postmarketos.org/wiki/Google_Pixel_3a_(google-sargo)#Camera does not have that much info. Front camera with Snapshot has some problems with color correction and saturation (maybe some fixed in non-released versions). Back camera missing autofocus driver, sdm670 kernel repo as an issue about it, and currently one gets a remarkably zoomed in image. You can find quite some examples in @rmader@mastodo.social profile :)

0
0
0

@dcz

under gnome + kernel 5.11 we have camera support.
can help testing/reporting if needed..

0
0
0

@dcz I'm not really a fan of the precedent that each phone will have two distinct camera support statuses, one for libcamera and one for libobscura. It was bad enough with Megapixels and libcamera both having to individually support devices. Do you have any thoughts about how we can avoid this future?

1
0
0

@newbyte I hope lessons from my experiment get incorporated elsewhere and I can move on to other projects.

In the end, it all depends on how much interest there is.

I also expect that the status will be the same for both, only because I can't find anything with kernel drivers that libcamera doesn't support.

2
0
0

@newbyte Oh, thanks for believing in me :) It's far from certain that the project is actually going to catch on :P

0
0
0

@dcz please share your opinion about 5
I'd like to have supper for it.

1
0
0

@Oleksii Never used it, never seen one. I haven't been tracking mobile Linux very closely recently.

What's your opinion?

1
0
0
@dcz Original PinePhone would be suitable target. It has smart sensor, so you'll hit different problems from L5.
0
0
1

@dcz I think is one of the best hardware candidate for FOSS. I have been using it for a few months and I'm happy with the hardware. Mostly I explore what kind of soft I could use. IMHO fairphone is the perfect sandbox for playing with software. I hope to make it my main driver one day.

1
0
0

@Oleksii What's the driver situation? How much is mainlined?
Does it run GNU/Linux today?

0
0
0

@dcz So your goal would be for e.g. libcamera to improve based on the ideas of libobscura, thus eventually making it obsolete?

1
0
0

@newbyte That would be great, yes. I stay in touch with the maintainers.

0
0
0

@jite Emulating v4l is awkward. I'd rather do Pipewire, although I reserve the right to change my mind.

0
0
0
@dcz Ok, so which phone should I play with? I'd like to try libobscura. README says "cargo run --bin glium_2". But I guess "cd libobscura/crates/vidi-examples" is needed before that. And that, on right system. On Librem 5, I get "this version of Cargo is older than the `2021` edition, and only supports `2015` and `2018` editions.".
1
0
0

@pavel I haven't gotten to the Librem 5 yet.
There is only support for UVC cameras now.

If you want to build it on the Librem 5, I would use a recent operating system (not PureOS) or install Rust using Rustup.

https://rustup.rs/

Yes, it is "execute random shell from the internet", but I think that's the only way to get recenr Rust on PureOS.

2
0
0
@dcz So far I found that I should be able to build on Droidian on oneplus6, but that has no working camera. I'd really like to play with rggb8 -> rgb888 conversion on the GPU, is that going to be feasible with the current code? (Any hints? :-) )
1
0
0

@pavel Yeah, it's actually implemented and you don't need a phone. There's the "bayer" binary that will pick up a file and decode it.

Check out --help.

2
0
1
@dcz Where do I get the bayer binary or its sources? Best I could find is crates/crispy/src/shaders/bayer.rs, and that seems to be something else.
1
0
0
@dcz (And yes, for the record, that's whats I'm looking for).
0
0
0
@dcz Thank you, that's much better. Is there any special setup to be done?

I'm getting permission denied. Running it as root does not fix stuff.

(Is there easy way to force CPU fallback just to test things)?

droidian@ONEPLUSA6003:/my/libobscura$ /my/libobscura/target/debug/raw --raw 5000,3000,8 /tmp/delme.raw RGGB /tmp/delme.tiff
KMS: DRM_IOCTL_MODE_CREATE_DUMB failed: Permission denied
thread 'main' panicked at crates/conv/src/bin/raw.rs:59:7:
1
0
0
@dcz Aha, and kmscube fails, too, and it has no manpage. GPUs are fun :-(.
1
0
0

@pavel Ouch. This looks like it's related to creating the GBM buffer?

1
0
0

@pavel It *should* be possible to skip the GBM parts and create regular OpenGL buffers, but my OpenGL skills are not enough to do it quickly.

0
0
0