mirror of
https://gitee.com/zlgopen/awtk.git
synced 2024-11-30 02:58:26 +08:00
add vgcanvas_set_stroke_gradient/vgcanvas_set_fill_gradient
This commit is contained in:
parent
accde8d3ae
commit
95154a7b24
@ -54,12 +54,12 @@ if OS_NAME == 'Windows':
|
||||
else:
|
||||
NANOVG_BACKEND='GL3'
|
||||
|
||||
#VGCANVAS='CAIRO'
|
||||
#NANOVG_BACKEND='GLES2'
|
||||
#NANOVG_BACKEND='GLES3'
|
||||
#NANOVG_BACKEND='AGG'
|
||||
#NANOVG_BACKEND='BGFX'
|
||||
#NANOVG_BACKEND='AGGE'
|
||||
VGCANVAS='CAIRO'
|
||||
|
||||
FRAME_BUFFER_FORMAT=''
|
||||
if VGCANVAS == 'CAIRO':
|
||||
|
@ -671,9 +671,9 @@ static cairo_pattern_t* vgcanvas_cairo_create_pattern_from_gradient(const vg_gra
|
||||
cairo_pattern_t* pattern = NULL;
|
||||
|
||||
if (gradient->type == VG_GRADIENT_LINEAR) {
|
||||
pattern = cairo_pattern_create_linear(sx, sy, ex, ey);
|
||||
pattern = cairo_pattern_create_linear(gradient->sx, gradient->sy, gradient->ex, gradient->ey);
|
||||
} else if (gradient->type == VG_GRADIENT_RADIAL) {
|
||||
pattern = cairo_pattern_create_radial(cx, cy, inr, cx, cy, outr);
|
||||
pattern = cairo_pattern_create_radial(gradient->sx, gradient->sy, gradient->ex, gradient->sx, gradient->sy, gradient->ey);
|
||||
}
|
||||
return_value_if_fail(pattern != NULL, NULL);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user