[vtkusers] Fwd: Questions about char drawing in VTK(Multi-level pie chart or ring chart)

Arnaud BARRE arnaud.barre at gmail.com
Wed Oct 31 11:55:05 EDT 2012


Dear Lucas,

I think you need to implement your own classes. There is no way to draw a
multi-level pie chart directly from a vtkChartPie (not from what I've seen
in the code). It should not be difficult. You could inherit from
vtkChartPie and overload the method "vtkPlot * vtkChartPie::AddPlot". You
method will create a vtkPlotMultiPie. The behavior of this class should be
quite the same than the class vtkPlotPie, but you need to give the good
inner radius (and not 0.0 as in vtkPlotPie) to the method
vtkContext2D::DrawEllipseWedge to draw the pies.

Arnaud


On Wed, Oct 31, 2012 at 3:39 PM, Lucas Lira Gomes <x8lucas8x at gmail.com>wrote:

> Hi everyone,
>
> i've been trying to draw a multi-level pie chart, also now as ring
> chart, for a while. Although I already succeeded in drawing a common
> pie chart using the vtkChartPie class, I'm completely stuck in the
> multi-level part. If someone could help me by giving any tips,
> snippets or suggestions, I'd be really grateful.
>
> Ring chart / Multilevel pie chart example:
> http://en.wikipedia.org/wiki/File:Disk_usage_(Boabab).png
>
> Thanks in advance, Lucas Lira Gomes.
>
>
> ----------------------------------------------------------------------------------
> Lucas Lira Gomes (llg)
> Linux User #533002
> Tel.: (81) 9235-0916
>
> www.about.me/lucasliragomes
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20121031/db0a96b4/attachment.htm>


More information about the vtkusers mailing list