<div dir="ltr"><div><div><div>Here is one actual code that creates conical gradients in cairo:<br><br><a href="https://github.com/synfig/synfig/blob/genete_new_cairo_core_2/synfig-core/src/modules/mod_gradient/conicalgradient.cpp#L360">https://github.com/synfig/synfig/blob/genete_new_cairo_core_2/synfig-core/src/modules/mod_gradient/conicalgradient.cpp#L360</a><br>
<br></div>You have just to adapt it to your 'Gradient' definition<br><br></div>See Synfig's Gradient definition here for reference:<br><a href="https://github.com/synfig/synfig/blob/genete_new_cairo_core_2/synfig-core/src/synfig/gradient.h">https://github.com/synfig/synfig/blob/genete_new_cairo_core_2/synfig-core/src/synfig/gradient.h</a><br>
<br></div>I hope it helps.</div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/1/29 Bobby Salazar <span dir="ltr"><<a href="mailto:bobby8934@gmail.com" target="_blank">bobby8934@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Is it possible to create a conical gradient using Cairo? I would like<br>
to be able to produce an effect similar to this picture:<br>
<br>
<a href="http://2.bp.blogspot.com/-b1G6OHdoCIA/TcOh3HYCyjI/AAAAAAAAAbg/JYi-vFIBZDs/s1600/SingleConicalGradient.png" target="_blank">http://2.bp.blogspot.com/-b1G6OHdoCIA/TcOh3HYCyjI/AAAAAAAAAbg/JYi-vFIBZDs/s1600/SingleConicalGradient.png</a><br>

<br>
Any help is appreciated!<br>
<span class="HOEnZb"><font color="#888888">--<br>
cairo mailing list<br>
<a href="mailto:cairo@cairographics.org">cairo@cairographics.org</a><br>
<a href="http://lists.cairographics.org/mailman/listinfo/cairo" target="_blank">http://lists.cairographics.org/mailman/listinfo/cairo</a><br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br>Carlos<br><a href="http://synfig.org" target="_blank">http://synfig.org</a><br>
</div>