-
-
Notifications
You must be signed in to change notification settings - Fork 332
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gst: set_trigger & software_trigger added for aravissrc
#927
Conversation
aravissrc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your pull request.
It would be better to make the trigger property take a string, which would also allow to change the trigger source to all available values.
gst/gstaravis.c
Outdated
@@ -1111,6 +1137,19 @@ gst_aravis_class_init (GstAravisClass * klass) | |||
GST_TYPE_ARV_USB_MODE, ARV_UV_USB_MODE_DEFAULT, | |||
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); | |||
|
|||
g_object_class_install_property | |||
(gobject_class, PROP_SET_TRIGGER, | |||
g_param_spec_boolean("set-trigger", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/set-trigger/trigger/
string property
gst/gstaravis.c
Outdated
@@ -417,6 +427,12 @@ gst_aravis_set_caps (GstBaseSrc *src, GstCaps *caps) | |||
return result; | |||
} | |||
|
|||
static void | |||
gst_aravis_trigger (GstAravis *src) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/gst_aravis_trigger/gst_aravis_software_trigger/
gst/gstaravis.c
Outdated
gst_aravis_signals[SIGNAL_SOFTWARE_TRIGGER] = | ||
g_signal_new ("software-trigger", G_TYPE_FROM_CLASS (klass), | ||
G_SIGNAL_RUN_LAST | G_SIGNAL_ACTION, G_STRUCT_OFFSET (GstAravisClass, | ||
trigger), NULL, NULL, NULL, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/trigger/software_trigger/
gst/gstaravis.c
Outdated
@@ -1131,6 +1170,8 @@ gst_aravis_class_init (GstAravisClass * klass) | |||
gstbasesrc_class->get_times = GST_DEBUG_FUNCPTR (gst_aravis_get_times); | |||
|
|||
gstpushsrc_class->create = GST_DEBUG_FUNCPTR (gst_aravis_create); | |||
|
|||
klass->trigger = gst_aravis_trigger; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/trigger/software_trigger/
@EmmanuelP Appreciate your feedback! I'll get them by today 👍 |
Thanks. I have pushed your patch with some tweaks making it actually use the software trigger. |
Overview
set-trigger
andsoftware-trigger
have been added toaravissrc
Example
set-trigger
(bool) andsoftware-trigger
(func) are addedPython
arv-software-trigger.py
Result