[paint-extents] Implement quadratic callback
This commit is contained in:
parent
7389efd8e0
commit
62ca2be39d
|
@ -102,6 +102,20 @@ hb_draw_extents_line_to (hb_draw_funcs_t *dfuncs,
|
||||||
add_point (extents, to_x, to_y);
|
add_point (extents, to_x, to_y);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
hb_draw_extents_quadratic_to (hb_draw_funcs_t *dfuncs,
|
||||||
|
void *data,
|
||||||
|
hb_draw_state_t *st,
|
||||||
|
float control_x, float control_y,
|
||||||
|
float to_x, float to_y,
|
||||||
|
void *)
|
||||||
|
{
|
||||||
|
hb_extents_t *extents = (hb_extents_t *)data;
|
||||||
|
|
||||||
|
add_point (extents, control_x, control_y);
|
||||||
|
add_point (extents, to_x, to_y);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
hb_draw_extents_cubic_to (hb_draw_funcs_t *dfuncs,
|
hb_draw_extents_cubic_to (hb_draw_funcs_t *dfuncs,
|
||||||
void *data,
|
void *data,
|
||||||
|
@ -128,6 +142,7 @@ static struct hb_draw_extents_funcs_lazy_loader_t : hb_draw_funcs_lazy_loader_t<
|
||||||
|
|
||||||
hb_draw_funcs_set_move_to_func (funcs, hb_draw_extents_move_to, nullptr, nullptr);
|
hb_draw_funcs_set_move_to_func (funcs, hb_draw_extents_move_to, nullptr, nullptr);
|
||||||
hb_draw_funcs_set_line_to_func (funcs, hb_draw_extents_line_to, nullptr, nullptr);
|
hb_draw_funcs_set_line_to_func (funcs, hb_draw_extents_line_to, nullptr, nullptr);
|
||||||
|
hb_draw_funcs_set_quadratic_to_func (funcs, hb_draw_extents_quadratic_to, nullptr, nullptr);
|
||||||
hb_draw_funcs_set_cubic_to_func (funcs, hb_draw_extents_cubic_to, nullptr, nullptr);
|
hb_draw_funcs_set_cubic_to_func (funcs, hb_draw_extents_cubic_to, nullptr, nullptr);
|
||||||
|
|
||||||
hb_draw_funcs_make_immutable (funcs);
|
hb_draw_funcs_make_immutable (funcs);
|
||||||
|
|
Loading…
Reference in New Issue