[PATCH] cam: Convert RGB variations to BGR
Pavel Machek
pavel at ucw.cz
Fri May 2 22:07:46 CEST 2025
Hi!
> > From looking at the code, soft ISP seemed to be able to do other stuff
> > than ARGB, but for some reason ARGB is selected by default, and I
> > guess I can get better performance by forcing right format.
>
> Software ISP debayering supports multiple output formats and `cam' can
> request a particular output format. For example,
>
> cam -c1 -C4 -s pixelformat=BGR888 -Ffoo#.ppm
>
> outputs the right thing. Example of requesting an output in a different
> format:
>
> cam -c1 -C4 -s pixelformat=ARGB8888 -Ffoo#.raw
>
> It works; is it a problem in your application?
Well, problem is that if you do something like "cam -c1 -Ffoo#.ppm" it
decides to use ARGB8888 and fails writing into ppm. That is not great.
> I don't mind enhancing the PPM writer but maybe you don't need the
> conversion there in the first place.
Agreed, I don't need it. People with hardware outputting RGB888 or
ARGB variants might like it.
Best regards,
Pavel
--
I don't work for Nazis and criminals, and neither should you.
Boycott Putin, Trump, and Musk!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://lists.libcamera.org/pipermail/libcamera-devel/attachments/20250502/5e36a02a/attachment.sig>
More information about the libcamera-devel
mailing list