mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-07 04:20:07 +01:00
more radial gradient tweaks
This commit is contained in:
3372
wx/svg/_nanosvg.c
3372
wx/svg/_nanosvg.c
File diff suppressed because it is too large
Load Diff
@@ -516,15 +516,17 @@ cdef class SVGgradient:
|
||||
@property
|
||||
def radialPoint(self):
|
||||
cdef float inverse[6]
|
||||
cdef float xo, yo, xc, yc, radius
|
||||
cdef float cx, cy, radius
|
||||
cdef float r1, r2
|
||||
|
||||
nsvg__xformInverse(inverse, self._ptr.xform)
|
||||
|
||||
nsvg__xformPoint(&xc, &yc, 0, 0, inverse)
|
||||
nsvg__xformPoint(&xo, &yo, 0, 1, inverse)
|
||||
radius = yo - yc;
|
||||
nsvg__xformPoint(&cx, &cy, 0, 0, inverse)
|
||||
nsvg__xformPoint(&r1, &r2, 0, 1, inverse)
|
||||
radius = r2 - cy
|
||||
|
||||
return (cx, cy, radius)
|
||||
|
||||
return (xo, yo, xc, yc, radius)
|
||||
|
||||
|
||||
#----------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user