st/oxr: Avoid calling oxr_action_cache_stop_output every time when xrSyncActions is called

This commit is contained in:
Zhongwang Zhang 2024-03-13 12:48:41 +08:00
parent 5f08427487
commit 099df066c6

View file

@ -1125,7 +1125,7 @@ oxr_action_cache_update(struct oxr_logger *log,
/* a cache can only have outputs or inputs, not both */
if (cache->output_count > 0) {
cache->current.active = true;
if (cache->stop_output_time < time) {
if (cache->stop_output_time > 0 && cache->stop_output_time < time) {
oxr_action_cache_stop_output(log, sess, cache);
}
} else if (cache->input_count > 0) {