Skip to content

cf_touch_get_all

Category: input
GitHub: cute_input.h


Returns an array of all touch events.

int cf_touch_get_all(CF_Touch** touch_all);
Parameters Description
touch_all An array of all CF_Touch touch events. See example section.

Return Value

Returns the number of CF_Touch events in touch_all.

Code Example

Looping over all touch events.

CF_Touch touches = NULL;
int touch_count = cf_touch_get_all(&touches);
for (int i = 0; i < touch_count; ++i) {
    do_something(touches[i]);
}

CF_Touch
cf_touch_get