Posts
1756
Following
90
Followers
166
Riding horses, hacking computers, phones and smartwatch.
@dos Thanks, I got it to work. I'm putting it into tui repository... and will probably need to reindent it.

For me, there's about 50% CPU usage, so there's still some room.

Yes, YUY2 will be faster; it will also have lower color resolution.

And agreed, there's nothing magic about fences. There's nothing magic about riding horse w/o reins and nothing magic about flying 737, either :-).
0
0
0
@dos Yes, there's more work to be done in the kernel; sometimes camera does not work after reboot, bayer-10 modes are not supported, ... :-(. And yes, it will take more power, but with phase-detection AF, it should be significantly better camera.
1
0
0
@dos :-) Hopefully. I'll believe things when I see them running locally.

BTW there's one more important thing this can probably do: take full-resolution photos while recording video.
1
0
0
@dos Thank you! I'll take closer look tomorrow or over the weekend. In the meantime, would you have Makefile or build command that goes with it?
1
0
0
@dos Exactly. That's a bit of big deal. That's why I'm trying to make sure this code does not go away. I had phase-detection auto-focus working at one point, but decided it is unusable as I did not see a way to scale down images quickly enough.

Plus it also adds possibility of zooming.
1
0
0
@dos Fences; that must be some kind of dark magic.

This code seems too good to be true. So, just to be sure, and in case you disappear tomorrow, can I add /* Copyright 2025 Sebastian Krzyszkowiak, GPLv2 */ and act according to that?
1
0
0
@fell @zaunz @postmarketOS The "pretty zoomed in" may be hardware limitation. The "90% range" is likely normal, too -- that's just how focus works. (Diopters, 1/m). But I like this. this is a real progress compared to my information from yesterday.
0
0
0
@fell @zaunz @postmarketOS And can it focus on infinity? Yesterday people were telling me camera can't physically focus far.

If it can focus on distant object, someone really needs to create patch for Megapixels.
1
0
0
@dos If you want to make sure, just point camera at the clock :-). gstreamer should get timing information at the input, so I'd expect dropped frames (not wrong speed) if things go wrong.
0
0
0
@dos I am not brave enough to debug gstreamer + openGL problems in the same process. You are either lucky or WIZARD :-).
0
0
0
@dos Camera is 23.5 FPS, IIRC. Do you have it under version control somewhere? This is a bit of achievement :-).
1
0
0
@fell @zaunz @postmarketOS Which camera is that? I was told mainline on 6T only supports macro camera and selfie...?
1
0
0
@dos But you only hexdumped first few pixels, right?

Is that buffer uncached or something?

I pushed current code to https://gitlab.com/tui/debayer-gpu .

Yes, with memcpy(), I'm getting same results as before. If I get rid of the memcpy(), and attempt to fwrite() the buffer directly, things actually slow down.

I can't easily connect gstreamer to that, I'm going through ramdisk for now. I'm using time ./ocam.py debayer for testing -- https://gitlab.com/tui/tui/-/blob/master/ucam/ocam.py?ref_type=heads
1
0
0
@dos Thanks for a patch. And yes, it makes the loop faster.. if you don't actually use the data. When used for loading/saving 720 images from the ramdisk, speed went from ~16 sec to ~21 sec.
1
0
0
OnePlus 6 ma tri fotaky, 2 vzadu a jeden selfie. #oneplus6 #linuxphone #oneplus6t Ty dva vzadu maji dost podobny parametry, jeden z nich na mainlinu funguje, druhy bohuzel ne, selfie funguje taky; tak proc neni podpora v Megapixels a internet plny fotek? No, protoze ten co funguje je makro kamerka ktera neumi fotit na dalku. Aha. Zahada vyresena.

OnePlus 6 has three cameras – two on the back and one selfie camera.
#oneplus6 #linuxphone #oneplus6t
The two rear cameras have quite similar specs. One of them works on mainline, the other unfortunately doesn't. The selfie camera works too.
So why isn't there support in Megapixels and why isn't the internet full of photos?
Well, because the one that works is the macro camera, which can't focus at a distance.
Ah. Mystery solved.
0
0
1
@jimmac @jamesh Sounds quite useful as a timer :-).
0
0
0
Opravuju ADSL modem... ten, co to schytal pri bource. Zatim jsem na opravu pouzil kondenzator z GME.cz (jeste jednou diky za trpelivost!), a papirovou karticku. Nechtelo se mi pajet, takze kondenzator je nasazen na nozicky toho vybuchleho. A ja bych mel brat sazky: Bude to fungovat?
0
0
2
@MOOMANiBE Ok, let's say that was an "interesting" hardware. And they probably had 'unlimited' ROM, so... yep, nice trick, but not even too crazy.
0
0
1
@mkyral Na radaru vidim vodu na zapadni hranici a vic vody v nemecku. Horko bych si v tuto chvili neodvazil predpovidat. Teplomer zatim ukazuje nejakych 23C, coz odpovida datum z intenetu (21C).

pavel@duo:/data/l/k$ weather lkpr
Current conditions at Praha / Ruzyne, Czech Republic (LKPR) 50-06N 014-15E 365M
Last updated Jul 03, 2025 - 03:30 AM EDT / 2025.07.03 0730 UTC
Temperature: 77 F (25 C)
Relative Humidity: 47%
Wind: from the N (360 degrees) at 12 MPH (10 KT)

Muj odhad je ze dneska nebude tak silene vedro -- diky te vode.
1
0
0
@dos Thanks. That really looks like black magic on the first look. On second look, maybe it is not that bad. Let me take another look tommorow.
0
0
0
Show older