lv_indev_gesture.h
API reference for lv_indev_gesture.h
See Also: Private HeaderThis header has a companion private implementation with internal data structures.lv_indev_gesture_private.h
Functions
indev/lv_indev_gesture.h:132function
lv_indev_set_pinch_up_threshold
Set the threshold for the pinch gesture scale up, when the scale factor of gesture reaches the threshold events get sent
void lv_indev_set_pinch_up_threshold(lv_indev_t *indev, float threshold)| Name | Type | Description |
|---|---|---|
indev | lv_indev_t * | pointer to the indev device containing the pinch recognizer |
threshold | float | threshold for a pinch up gesture to be recognized |
indev/lv_indev_gesture.h:140function
lv_indev_set_pinch_down_threshold
Set the threshold for the pinch gesture scale down, when the scale factor of gesture reaches the threshold events get sent
void lv_indev_set_pinch_down_threshold(lv_indev_t *indev, float threshold)| Name | Type | Description |
|---|---|---|
indev | lv_indev_t * | pointer to the indev device containing the pinch recognizer |
threshold | float | threshold for a pinch down gesture to be recognized |
indev/lv_indev_gesture.h:147function
lv_indev_set_rotation_rad_threshold
Set the rotation threshold in radian for the rotation gesture
void lv_indev_set_rotation_rad_threshold(lv_indev_t *indev, float threshold)| Name | Type | Description |
|---|---|---|
indev | lv_indev_t * | pointer to the indev device containing the rotation recognizer |
threshold | float | threshold in radian for a rotation gesture to be recognized |
indev/lv_indev_gesture.h:183function
lv_indev_set_gesture_data
Sets the state of the recognizer to a indev data structure, it is usually called from the indev read callback
void lv_indev_set_gesture_data(lv_indev_data_t *data, lv_indev_gesture_recognizer_t *recognizer, lv_indev_gesture_type_t type)| Name | Type | Description |
|---|---|---|
data | lv_indev_data_t * | the indev data |
recognizer | lv_indev_gesture_recognizer_t * | pointer to a gesture recognizer |
type | lv_indev_gesture_type_t |
indev/lv_indev_gesture.h:236function
lv_indev_gesture_recognizers_set_data
Set the lv_indev_data_t struct from the recognizer data. To be called in the indev read_cb.
void lv_indev_gesture_recognizers_set_data(lv_indev_t *indev, lv_indev_data_t *data)| Name | Type |
|---|---|
indev | lv_indev_t * |
data | lv_indev_data_t * |
Enums
lv_indev_gesture_state_t
| Name | Value |
|---|---|
LV_INDEV_GESTURE_STATE_NONE | 0 |
LV_INDEV_GESTURE_STATE_ONGOING | |
LV_INDEV_GESTURE_STATE_RECOGNIZED | |
LV_INDEV_GESTURE_STATE_ENDED | |
LV_INDEV_GESTURE_STATE_CANCELED |
Structs
struct
lv_indev_touch_data
| Member | Type | Description |
|---|---|---|
point | lv_point_t | |
state | lv_indev_state_t | |
id | uint8_t | |
timestamp | uint32_t |
struct
lv_indev_gesture_recognizer
| Member | Type | Description |
|---|---|---|
type | lv_indev_gesture_type_t | |
state | lv_indev_gesture_state_t | |
info | lv_indev_gesture_t * | |
scale | float | |
rotation | float | |
distance | float | |
speed | float | |
two_fingers_swipe_dir | lv_dir_t | |
config | lv_indev_gesture_configuration_t * | |
recog_fn | lv_recognizer_func_t |
Typedefs
indev/lv_indev_gesture.h:41typedef
lv_indev_gesture_recognizer_t
typedef struct lv_indev_gesture_recognizer lv_indev_gesture_recognizer_tUsed by 7 functions
lv_indev_gesture_detect_pinch— paramrecognizerlv_indev_gesture_detect_rotation— paramrecognizerlv_indev_gesture_detect_two_fingers_swipe— paramrecognizerlv_indev_set_gesture_data— paramrecognizerlv_indev_get_gesture_center_point— paramrecognizerlv_indev_get_gesture_primary_point— paramrecognizerlv_indev_recognizer_is_active— paramrecognizer
indev/lv_indev_gesture.h:42typedef
lv_indev_touch_data_t
typedef struct lv_indev_touch_data lv_indev_touch_data_tUsed by 4 functions
lv_indev_gesture_detect_pinch— paramtoucheslv_indev_gesture_detect_rotation— paramtoucheslv_indev_gesture_detect_two_fingers_swipe— paramtoucheslv_indev_gesture_recognizers_update— paramtouches
indev/lv_indev_gesture.h:44typedef
lv_indev_gesture_t
typedef struct lv_indev_gesture lv_indev_gesture_tindev/lv_indev_gesture.h:45typedef
lv_indev_gesture_configuration_t
typedef struct lv_indev_gesture_configuration lv_indev_gesture_configuration_tindev/lv_indev_gesture.h:47typedef
lv_recognizer_func_t
typedef void(* lv_recognizer_func_t) (lv_indev_gesture_recognizer_t *, lv_indev_touch_data_t *, uint16_t)Dependencies
Indirect dependencies
lv_anim.hlv_area.hlv_array.hlv_assert.hlv_bidi.hlv_color.hlv_color_op.hlv_conf_internal.hlv_conf_kconfig.hlv_display.hlv_draw.hlv_draw_arc.hlv_draw_blur.hlv_draw_buf.hlv_draw_image.hlv_draw_label.hlv_draw_line.hlv_draw_rect.hlv_draw_triangle.hlv_event.hlv_ext_data.hlv_flex.hlv_font.hlv_fs.hlv_grad.hlv_grid.hlv_group.hlv_image_decoder.hlv_image_dsc.hlv_indev.hlv_layout.hlv_ll.hlv_log.hlv_math.hlv_matrix.hlv_mem.hlv_obj_class.hlv_obj_draw.hlv_obj_event.hlv_obj_pos.hlv_obj_property.hlv_obj_property_names.hlv_obj_scroll.hlv_obj_style.hlv_obj_style_gen.hlv_obj_tree.hlv_palette.hlv_profiler.hlv_profiler_builtin.hlv_sprintf.hlv_string.hlv_style.hlv_style_gen.hlv_style_properties.hlv_symbol_def.hlv_text.hlv_tick.hlv_timer.hlv_types.h
How is this guide?
Last updated on