Commit Graph

44 Commits

Author SHA1 Message Date
Martijn Braam
e0e94a62b2 Set names for the pipeline threads 2024-01-18 02:35:51 +01:00
Martijn Braam
4032b53592 Don't update metadata faster than the framerate 2024-01-18 02:34:51 +01:00
Martijn Braam
9d189b88b4 Support rendering YUV formatted frames 2023-11-26 14:19:29 +01:00
Martijn Braam
a6de61f475 Implement whitebalance 2023-08-16 14:45:57 +02:00
Martijn Braam
9a685eb839 Use xfer function from libmegapixels instead of v4l 2023-07-22 16:41:38 +02:00
Martijn Braam
128a3696c4 Add a switch between SRGB and linear colors in the debayer shader 2023-07-22 16:29:23 +02:00
Martijn Braam
16dfb9ba19 Close the AAA loop 2023-07-21 14:06:32 +02:00
Martijn Braam
f26f81e3f1 Refactor controls more 2023-07-21 13:19:26 +02:00
Martijn Braam
e90f16dcfa AE stats 2023-07-21 12:08:12 +02:00
Martijn Braam
e97ce527b0 Pause frame processing when window is not active 2023-07-20 18:27:17 +02:00
Martijn Braam
6e8293116b Process pipeline refactoring 2023-07-20 17:40:00 +02:00
Martijn Braam
2a7a5d37e6 Fix burst length calculation 2023-07-20 16:55:39 +02:00
Martijn Braam
b86c816c34 Pick preview mode closest to screen size 2023-07-20 16:50:16 +02:00
Martijn Braam
d51a2fb263 Refactor controls 2023-07-20 16:36:58 +02:00
Martijn Braam
c4969cec6c Continue refactoring of global state 2023-07-20 11:39:30 +02:00
Martijn Braam
2c3a16332d Ensure the capture terminates 2023-07-12 16:06:32 +02:00
Martijn Braam
472f84b741 Don't crash on the L5 2023-07-12 14:48:52 +02:00
Martijn Braam
3ee314a68d Add libmegapixels 2023-07-11 23:43:23 +02:00
Martijn Braam
b5161db18e Add DCP calibration files for sensors
Read .dcp files stored in the same directory as the camera configuration
files and copy over the calibration curves into the DNG files after
taking a picture.
2023-07-07 17:14:24 +02:00
ArenM
f43fcdb241 Set bridge resolution when setting the mode (MR 31)
sun6i-csi-bridge will return EINVAL if the resolution it is configured
with is different than the resolution the camera is configured with. So
we have to set it's resolution when changing the camera resolution.
2023-05-28 13:42:20 -04:00
ArenM
ebfcf10fa6 get pad from vid_if_bridge instead of io_v4l (MR 31)
The camera pipline on the PinePhone the cameras connected to a bridge
node instead of directly to the output.
2023-05-26 11:22:44 -04:00
Luigi311
f1ad116a23 Increase burst minimum (MR 28) 2023-02-02 14:01:55 +01:00
Martijn Braam
444cacfa6c Workaround for camera enumeration (MR 9)
The setup_camera() function removes found media devices
from the device list on run but somehow avoids this on
the pinephone due more bugs in the software. This makes
it run with a clean list for every camera to fix this.

The proper fix is dropping the whole setup_camera()
procedure in the future.
2022-11-22 14:51:46 +01:00
Sebastian Krzyszkowiak
1dc3d3d455 device: Always use a pair of driver and subdev names to find the device (MR 9)
Otherwise Megapixels fails to find the correct device on systems where
there are multiple media devices handled by the same driver, like imx8mq.
2022-11-21 20:51:57 +01:00
Martijn Braam
89f7abd749 Capture at least 2 frames
Current post processing scripts assume at least 2 frames are captured.
With the rear pinephone camera the automatic gain control will always
raise the gain high enough that the frame count will be 2 or higher. For
the front camera the gain might be zero causing the burst to be 1 frame
long.
2022-06-27 16:50:05 +02:00
Martijn Braam
2b0569a903 Set captures_remaining properly in all cases 2022-06-27 15:42:29 +02:00
Martijn Braam
77a3abf4a6 Only disable flash when flashing is enabled
If the flash was disabled and screne flash is used it will try to set
the screen brightness back to the original value. Because the check for
mp_flash_enable and mp_flash_disable is different there's cases where
enable wasn't run but disable is, causing it to use the initial zero
brightness as the restore value.
2022-06-27 15:40:44 +02:00
Martijn Braam
46b07c6c4d Move postprocessor script to a gsetting (MR 18) 2022-06-24 14:38:11 +02:00
Yassine Oudjana
7dbc2288d0 io_pipeline: Setup media links and formats (MR 13) 2022-06-21 17:31:16 +02:00
Yassine Oudjana
a4c2c1ec1f Move mode types and functions to a new object (MR 13)
Rename MPCameraMode to a more generic MPMode and move it along
with related functions to a new object in preparation for using
it in the device object.
2022-06-21 17:30:16 +02:00
Martijn Braam
899748df46 Change burst length depending on gain
The burst_length is now calculated before taking the first picture
by increasing the number of frames when the sensor gain is raised.
2022-06-21 16:29:23 +02:00
Martijn Braam
d41fb6745a save flash state in the exif data 2022-06-21 14:39:08 +02:00
Benjamin Schaaf
772db36877 Make clang-format more aggressive
clang-format always manages to mix spaces into tab-based indentation.
Since we already require an exact tab-width of 8 it makes more sense to
use spaces.
2021-11-13 00:06:11 +11:00
Benjamin Schaaf
a92104e27c Add clang-format as part of CI 2021-11-12 21:47:34 +11:00
Benjamin Schaaf
24835cdc25 Implement flash
Fixes #5
2021-11-12 18:29:34 +11:00
WebFreak001
974fafc1d1 focus now only triggerable once in parallel 2021-07-30 17:48:20 +02:00
WebFreak001
7314739dfc free cameras on process exit 2021-07-30 17:48:19 +02:00
WebFreak001
1282a75db9 run most camera control setting in background
makes trigger focus, continuous focus, autogain, gain ctrl, auto
exposure, exposure ctrl run in background to not block the UI thread.

The camera updates the image while this is in progress, so you can for
example see the camera live focus as on common other phones.
2021-07-30 17:48:17 +02:00
Martijn Braam
5ad97d03f6 Add save-dng setting 2021-06-14 00:32:55 +02:00
Benjamin Schaaf
64b75bcbe5 Preview rotation follows device 2021-05-04 00:06:55 +10:00
Benjamin Schaaf
8ccf1451ed Fix image capture 2021-05-01 21:32:32 +10:00
Benjamin Schaaf
207aabf16a Add workaround for OV5640 capture mode not being set on first start after reboot 2021-05-01 19:57:15 +10:00
Benjamin Schaaf
36b7b2b38d Fix gain and exposure being switched in io pipeline 2021-04-26 22:31:14 +10:00
Benjamin Schaaf
91817b167a Reorganization, replacing CPU debayering entirely 2021-04-18 23:13:56 +10:00