diff --git a/_Sidebar.md b/_Sidebar.md index 6b22611..27d41bc 100644 --- a/_Sidebar.md +++ b/_Sidebar.md @@ -2,6 +2,8 @@ ### Contenu +- [Configuration](./configuration) +- [Résolutions caméra](./camera_resolution) - [Environnement Python](./python_environnement) - [Mode Kiosk](./kiosk) - [Démarrage silencieux](./demarrage_silencieux) \ No newline at end of file diff --git a/camera_resolution.md b/camera_resolution.md new file mode 100644 index 0000000..f20c92e --- /dev/null +++ b/camera_resolution.md @@ -0,0 +1,96 @@ +# Trouver les résolutions d'image disponibles sur une caméra + +## Webcam V4L2 + +En utilisant `v4l2-ctl`, on peut vérifier les modes disponibles pour une caméra : + +``` +$ v4l2-ctl --list-formats-ext -k +ioctl: VIDIOC_ENUM_FMT + Type: Video Capture + + [0]: 'YUYV' (YUYV 4:2:2) + Size: Discrete 640x480 + Interval: Discrete 0.033s (30.000 fps) + Interval: Discrete 0.040s (25.000 fps) + Interval: Discrete 0.050s (20.000 fps) + Interval: Discrete 0.067s (15.000 fps) + Interval: Discrete 0.100s (10.000 fps) + Interval: Discrete 0.200s (5.000 fps) +[...] + Size: Discrete 1280x960 + Interval: Discrete 0.133s (7.500 fps) + Interval: Discrete 0.200s (5.000 fps) + [1]: 'MJPG' (Motion-JPEG, compressed) + Size: Discrete 640x480 + Interval: Discrete 0.033s (30.000 fps) + Interval: Discrete 0.040s (25.000 fps) + Interval: Discrete 0.050s (20.000 fps) + Interval: Discrete 0.067s (15.000 fps) + Interval: Discrete 0.100s (10.000 fps) + Interval: Discrete 0.200s (5.000 fps) +[...] + Size: Discrete 1280x720 + Interval: Discrete 0.033s (30.000 fps) + Interval: Discrete 0.040s (25.000 fps) + Interval: Discrete 0.050s (20.000 fps) + Interval: Discrete 0.067s (15.000 fps) + Interval: Discrete 0.100s (10.000 fps) + Interval: Discrete 0.200s (5.000 fps) + Size: Discrete 1280x960 + Interval: Discrete 0.033s (30.000 fps) + Interval: Discrete 0.040s (25.000 fps) + Interval: Discrete 0.050s (20.000 fps) + Interval: Discrete 0.067s (15.000 fps) + Interval: Discrete 0.100s (10.000 fps) + Interval: Discrete 0.200s (5.000 fps) +``` + +## Module caméra Raspberry Pi + +Voir ici pour les résolutions disponibles pour les modules V1 (5MP) et V2 (8MP) : + +[[https://picamera.readthedocs.io/en/release-1.13/fov.html#sensor-modes]] + +Le module v3 supporte les [modes suivants](https://github.com/raspberrypi/linux/blob/rpi-5.15.y/drivers/media/i2c/imx708.c) : + +``` +mode_4608x2592_regs (4608x2592) +mode_2x2binned_regs (2304x1296) +mode_2x2binned_720p_regs (1532x 864) +mode_hdr_regs (2304x1296) +``` + +On peut aussi utiliser la commande `libcamera-hello --list-cameras` pour obtenir des infos sur le module connecté : + +``` +Available cameras +----------------- +0 : imx708 [4608x2592] (/base/soc/i2c0mux/i2c@1/imx708@1a) + Modes: 'SRGGB10_CSI2P' : 1536x864 [120.13 fps - (0, 0)/4608x2592 crop] + 2304x1296 [56.03 fps - (0, 0)/4608x2592 crop] + 4608x2592 [14.35 fps - (0, 0)/4608x2592 crop] +``` + +## Showmewebcam + +La résolution maximale est de 1600x900. + +## Réflexe numérique + +En utilisant gphoto, on peut trouver les résolutions disponibles (ici avec un nikon D3000): + +``` +$ gphoto --list-all-config | grep imagesize +/main/capturesettings/imagesize +$ gphoto2 --get-config=/main/capturesettings/imagesize +/main/imgsettings/imagesize +Label: Image Size +Readonly: 0 +Type: RADIO +Current: 1936x1296 +Choice: 0 3872x2592 +Choice: 1 2896x1944 +Choice: 2 1936x1296 +END +``` diff --git a/configuration.md b/configuration.md new file mode 100644 index 0000000..9f298df --- /dev/null +++ b/configuration.md @@ -0,0 +1,31 @@ +# Documentation du fichier de configuration + +Un fichier de configuration nommé `config.toml` sera recherché dans les dossiers suivants : `./`, `~/.` et `~/.config/`. +Son contenu est le suivant : + +``` +[DEFAULT] +# Camera type - can be : showmewebcam, picam, webcam, dslr +cam_type = 'webcam' +use_date_for_folder = false +file_extension = 'jpg' +jpg_quality = 88 +projects_folder = '' +onion_skin_onstartup = true +onionskin_alpha_default = 0.5 +fullscreen_bool = true +screen_w = 1920 +screen_h = 1080 +framerate = 16 +ffmpeg_path = '/usr/bin/ffmpeg' +v4l2-ctl_path = '/usr/bin/v4l2-ctl' +export_options = 'scale=1920:-1,crop=1920:1080' +[CAMERA] +cam_w = 1280 +cam_h = 960 +vflip = 0 +hflip = 0 +auto_exposure = 1 +white_balance_auto_preset = 1 +video_bitrate=25000000 +``` \ No newline at end of file