lv_draw_line.h
Functions
-
void lv_draw_line_dsc_init(lv_draw_line_dsc_t *dsc)
Initialize a line draw descriptor
- Parameters:
dsc – pointer to a draw descriptor
-
lv_draw_line_dsc_t *lv_draw_task_get_line_dsc(lv_draw_task_t *task)
Try to get a line draw descriptor from a draw task.
- Parameters:
task – draw task
- Returns:
the task's draw descriptor or NULL if the task is not of type LV_DRAW_TASK_TYPE_LINE
-
void lv_draw_line(lv_layer_t *layer, const lv_draw_line_dsc_t *dsc)
Create a line draw task
- Parameters:
layer – pointer to a layer
dsc – pointer to an initialized
lv_draw_line_dsc_t
variable
-
struct lv_draw_line_dsc_t
Public Members
-
lv_draw_dsc_base_t base
-
lv_point_precise_t p1
The first point of the line. If
LV_USE_FLOAT
is enabled float number can be also used
-
lv_point_precise_t p2
The second point of the line. If
LV_USE_FLOAT
is enabled float number can be also used
-
lv_color_t color
The color of the line
-
int32_t width
The width (thickness) of the line
-
int32_t dash_width
The length of a dash (0: don't dash)
-
int32_t dash_gap
The length of the gaps between dashes (0: don't dash)
-
lv_opa_t opa
Opacity of the line in 0...255 range. LV_OPA_TRANSP, LV_OPA_10, LV_OPA_20, .. LV_OPA_COVER can be used as well
-
uint8_t round_start
Make the line start rounded
-
uint8_t round_end
Make the line end rounded
-
uint8_t raw_end
1: Do not bother with line ending (if it's not visible for any reason)
-
lv_draw_dsc_base_t base