summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorDaniel Scally <dan.scally@ideasonboard.com>2023-01-10 08:49:30 +0000
committerDaniel Scally <dan.scally@ideasonboard.com>2023-01-16 15:22:38 +0000
commit29be8034518c0babbf6334d3ef6fc9ffe30e6b70 (patch)
treed1e58680f71b270e3b94dad162e5c45c645f6967 /meson.build
parent3a4e214882b362dc6dccd28d0862a258af75cf33 (diff)
lib/mjpeg_encoder: Add an MJPEG encoder for YUV420 data
MJPEG is an extremely useful format given its compression allows high framerates even over limited bandwith USB connections. Add an MJPEG encoder class that converts YUV420 data into MJPEG data. Where a libcamera-source does not support MJPEG natively, convert YUV420 into MJPEG if the user tries to set MJPEG format. Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Signed-off-by: Daniel Scally <dan.scally@ideasonboard.com>
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build6
1 files changed, 6 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 8101676..a8b54d1 100644
--- a/meson.build
+++ b/meson.build
@@ -54,6 +54,8 @@ summary({ 'Sources': uvc_gadget_git_version, }, section : 'Versions')
cc = meson.get_compiler('c')
libcamera = dependency('libcamera', required : false)
+libjpeg = dependency('libjpeg', required : false)
+threads = dependency('threads', required : false)
conf = configuration_data()
@@ -61,6 +63,10 @@ if libcamera.found()
conf.set('HAVE_LIBCAMERA', true)
endif
+if libjpeg.found() and threads.found()
+ conf.set('CONFIG_CAN_ENCODE', true)
+endif
+
configure_file(output : 'config.h', configuration : conf)
config_includes = include_directories('.')