summaryrefslogtreecommitdiffstats
path: root/include/xas
diff options
context:
space:
mode:
authorXANTRONIX Development2022-03-16 01:37:23 -0400
committerXANTRONIX Development2022-03-16 01:37:23 -0400
commitc37b073de965d23a172a5364af5e541d9738b12b (patch)
treed7b1553ab16edb512b61e6849bc032d5f888c33c /include/xas
parent7d65f737f07a1e9f64f84b587dbd7b87832ef3fd (diff)
downloadxas-c37b073de965d23a172a5364af5e541d9738b12b.tar.gz
xas-c37b073de965d23a172a5364af5e541d9738b12b.tar.bz2
xas-c37b073de965d23a172a5364af5e541d9738b12b.zip
Add index argument to xas_object_start(), stop()
Changes: * Refactor all start, stop dispatch methods to accept an index argument, whether it is used or not * Use 'index' slot of xas_seq_event to store index to pass to xas_object_start(), xas_object_stop() for start and stop events
Diffstat (limited to 'include/xas')
-rw-r--r--include/xas/object.h8
-rw-r--r--include/xas/seq.h6
2 files changed, 8 insertions, 6 deletions
diff --git a/include/xas/object.h b/include/xas/object.h
index 5780c7d..1fd3b8c 100644
--- a/include/xas/object.h
+++ b/include/xas/object.h
@@ -5,9 +5,9 @@
typedef struct _xas_object xas_object;
-typedef int (*xas_object_start_callback)(xas_object *object);
+typedef int (*xas_object_start_callback)(xas_object *object, size_t index);
-typedef int (*xas_object_stop_callback)(xas_object *object);
+typedef int (*xas_object_stop_callback)(xas_object *object, size_t index);
typedef int (*xas_object_set_gain_callback)(xas_object *object, float gain);
@@ -34,9 +34,9 @@ struct _xas_object {
void xas_object_init(xas_object *object);
-int xas_object_start(xas_object *object);
+int xas_object_start(xas_object *object, size_t index);
-int xas_object_stop(xas_object *object);
+int xas_object_stop(xas_object *object, size_t index);
int xas_object_set_gain(xas_object *object, float gain);
diff --git a/include/xas/seq.h b/include/xas/seq.h
index 887276b..05b1919 100644
--- a/include/xas/seq.h
+++ b/include/xas/seq.h
@@ -62,11 +62,13 @@ void xas_seq_destroy(xas_seq *seq);
int xas_seq_add_event_off(xas_seq *seq,
xas_spatial_object *object,
- struct timeval timestamp);
+ struct timeval timestamp,
+ size_t index);
int xas_seq_add_event_on(xas_seq *seq,
xas_spatial_object *object,
- struct timeval timestamp);
+ struct timeval timestamp,
+ size_t index);
int xas_seq_add_set_position(xas_seq *seq,
xas_spatial_object *object,