I have published the snippet of code that implements a GPU-based ISP with bunch of corrections and encodes video in real time on the Librem 5. Feel free to take parts of it and use in your apps and frameworks... or record your cats 😼
https://source.puri.sm/-/snippets/1223
#linuxmobile #mobilelinux #linuxphones #camera #librem5 #shotonlibrem5
@pavel It shows the right way and runs reliably for hours here on crimson. There should be no crashes whatsoever. Could be some regression on GStreamer side, but on newer distros you should rather use GTK4 and GtkGraphicsOffload instead anyway.
Of course simpler shaders allow for higher performance, the challenge is in simplifying the shader without making the output shitty ;)
@pavel ...and remember that it won't work on byzantium/bullseye.
@pavel rotate-method sets what gets passed to wl_surface::set_buffer_transform verbatim, and the camera is rotated 90° counter clock-wise in relation to the screen, so it should be 1. Unless I'm getting something wrong, it smells like a bug in newer phoc.
By the way, with just a one-line change (commenting out mp4mux/filesink, uncommenting flvmux/rtmpsink and adjusting the URL) you can stream online rather than to a local file 😎
(fwiw this screenshot is from before autofocus, white balance and most of image processing stuff was there)
#linuxmobile #mobilelinux #linuxphones #camera #librem5 #shotonlibrem5
Ladies, gentlemen and enbies of the Fedi... the circle is now complete. We have mobile Linux cat videos on The Fediverse.