diff options
author | XANTRONIX Development | 2022-03-15 23:42:09 -0400 |
---|---|---|
committer | XANTRONIX Development | 2022-03-15 23:42:09 -0400 |
commit | 2e89b0d179351ec698c7418836279824d79c728f (patch) | |
tree | 9690bc759bf23fdd55e492e629a68eab120a3909 /src | |
parent | ed12dddb60fe4b7a4d16274dd5fc3d12a1f5ebf0 (diff) | |
download | xas-2e89b0d179351ec698c7418836279824d79c728f.tar.gz xas-2e89b0d179351ec698c7418836279824d79c728f.tar.bz2 xas-2e89b0d179351ec698c7418836279824d79c728f.zip |
Remove useless objtype from xas_seq_event
Diffstat (limited to 'src')
-rw-r--r-- | src/seq.c | 35 |
1 files changed, 0 insertions, 35 deletions
@@ -166,7 +166,6 @@ int xas_seq_add_event_off(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_OFF; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; @@ -193,7 +192,6 @@ int xas_seq_add_event_on(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_ON; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; @@ -221,7 +219,6 @@ int xas_seq_add_set_position(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_POSITION; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; ev->point = point; @@ -250,7 +247,6 @@ int xas_seq_add_set_heading(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_HEADING; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; ev->heading = heading; @@ -279,7 +275,6 @@ int xas_seq_add_set_speed(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_SPEED; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; ev->speed = speed; @@ -308,7 +303,6 @@ int xas_seq_add_set_gain(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_ON; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = object; ev->timestamp = timestamp; ev->gain = gain; @@ -337,7 +331,6 @@ int xas_seq_add_set_bank(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_BANK_INDEX; - ev->objtype = XAS_SEQ_OBJECT_BANK_PLAYER; ev->object = object; ev->timestamp = timestamp; ev->index = index; @@ -366,7 +359,6 @@ int xas_seq_add_set_player_flags(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_PLAYER_FLAGS; - ev->objtype = XAS_SEQ_OBJECT_BANK_PLAYER; ev->object = object; ev->timestamp = timestamp; ev->flags = flags; @@ -395,7 +387,6 @@ int xas_seq_add_set_synth_type(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_SYNTH_TYPE; - ev->objtype = XAS_SEQ_OBJECT_SYNTH; ev->object = object; ev->timestamp = timestamp; ev->synth_type = type; @@ -424,7 +415,6 @@ int xas_seq_add_set_frequency(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SET_FREQUENCY; - ev->objtype = XAS_SEQ_OBJECT_SYNTH; ev->object = object; ev->timestamp = timestamp; ev->frequency = frequency; @@ -453,7 +443,6 @@ int xas_seq_add_phrase(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_SPEECH; - ev->objtype = XAS_SEQ_OBJECT_VOX; ev->object = object; ev->timestamp = timestamp; ev->phrase = phrase; @@ -480,7 +469,6 @@ int xas_seq_add_stop(xas_seq *seq, } ev->type = XAS_SEQ_EVENT_STOP; - ev->objtype = XAS_SEQ_OBJECT_ANY; ev->object = NULL; ev->timestamp = timestamp; ev->flags = 0; @@ -529,46 +517,26 @@ static int event_trigger(xas_spatial_scene *scene, xas_seq_event *ev) { break; case XAS_SEQ_EVENT_SET_FREQUENCY: - if (ev->objtype != XAS_SEQ_OBJECT_SYNTH) { - goto error_invalid_event; - } - xas_synth_set_frequency(ev->object->ctx, ev->frequency); break; case XAS_SEQ_EVENT_SET_SYNTH_TYPE: - if (ev->objtype != XAS_SEQ_OBJECT_SYNTH) { - goto error_invalid_event; - } - xas_synth_set_type(ev->object->ctx, ev->synth_type); break; case XAS_SEQ_EVENT_SET_BANK_INDEX: - if (ev->objtype != XAS_SEQ_OBJECT_BANK_PLAYER) { - goto error_invalid_event; - } - xas_bank_player_set_entry(ev->object->ctx, ev->index); break; case XAS_SEQ_EVENT_SET_PLAYER_FLAGS: - if (ev->objtype != XAS_SEQ_OBJECT_BANK_PLAYER) { - goto error_invalid_event; - } - xas_bank_player_set_flags(ev->object->ctx, ev->flags); break; case XAS_SEQ_EVENT_SPEECH: - if (ev->objtype != XAS_SEQ_OBJECT_VOX) { - goto error_invalid_event; - } - xas_vox_say(ev->object->ctx, ev->phrase); xas_vox_generate(ev->object->ctx); @@ -579,9 +547,6 @@ static int event_trigger(xas_spatial_scene *scene, xas_seq_event *ev) { } return 0; - -error_invalid_event: - return -1; } static inline void timerupdate(struct timeval *tv, |