[PATCH 1/3] gstreamer: Add GST_PARAM_CONDITIONALLY_AVAILABLE flag to properties
Jaslo Ziska
jaslo at ziska.de
Tue Apr 22 16:25:19 CEST 2025
Add the GST_PARAM_CONDITIONALLY_AVAILABLE flag to the camera properties
to mark the property as conditionally available, i.e. it might only be
present depending on the camera / pipeline.
Signed-off-by: Jaslo Ziska <jaslo at ziska.de>
---
src/gstreamer/gstlibcamera-controls.cpp.in | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/gstreamer/gstlibcamera-controls.cpp.in b/src/gstreamer/gstlibcamera-controls.cpp.in
index 89c530da..28604a3c 100644
--- a/src/gstreamer/gstlibcamera-controls.cpp.in
+++ b/src/gstreamer/gstlibcamera-controls.cpp.in
@@ -124,7 +124,9 @@ g_param_spec_{{ ctrl.gtype }}(
{%- elif ctrl.gtype in ['float', 'int', 'int64', 'uchar'] %}
{{ ctrl.min }}, {{ ctrl.max }}, {{ ctrl.default }},
{%- endif %}
- (GParamFlags) (GST_PARAM_CONTROLLABLE | G_PARAM_READWRITE |
+ (GParamFlags) (GST_PARAM_CONDITIONALLY_AVAILABLE |
+ GST_PARAM_CONTROLLABLE |
+ G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS)
)
{%- endset %}
@@ -138,7 +140,8 @@ g_param_spec_{{ ctrl.gtype }}(
"{{ ctrl.name }}",
{{ ctrl.description|format_description|indent_str('\t\t\t') }},
{{ spec|indent_str('\t\t\t') }},
- (GParamFlags) (GST_PARAM_CONTROLLABLE |
+ (GParamFlags) (GST_PARAM_CONDITIONALLY_AVAILABLE |
+ GST_PARAM_CONTROLLABLE |
G_PARAM_READWRITE |
G_PARAM_STATIC_STRINGS)
)
--
2.49.0
More information about the libcamera-devel
mailing list