[cairo] Conical Gradient
simon.sapin at exyr.org
Mon Jan 28 16:08:06 PST 2013
Le 29/01/2013 00:24, Bobby Salazar a écrit :
> Is it possible to create a conical gradient using Cairo? I would like
> to be able to produce an effect similar to this picture:
> Any help is appreciated!
Yes, since cairo 1.12, with mesh a pattern:
"Tensor-product patch meshes" are a super-set of many gradient types
including (if I understand correctly) linear, radial and conical gradients.
It’s not super obvious, but you can get a conical gradient with one
patch per "step", each shaped like a pie slice.
Might be useful: http://tavmjong.free.fr/SVG/MESH/Mesh.html
More information about the cairo