[vtkusers] labelling iso-lines

Bill Lorensen bill.lorensen at gmail.com
Thu May 20 21:28:07 EDT 2010


Great. I'm happy you found the example useful. I encourage you to add
an example that uses vtkVectorText and vtkFollower.

Bill

On Thu, May 20, 2010 at 6:57 PM, rashedk <rashed.vtk at googlemail.com> wrote:
>
> Thanks Bill. I found the example very useful and helpful.
>
> One small problem which you had put as a note: the labels are 2D actors and
> thus show up even when they are obstructed in the field-of-view by a 3D
> surface. I guess there is no easy workaround if one uses
> vtkLabeledDataMapper as it is sub-classed from vtkMapper2D. But a quick
> dirty fix is to drop vtkLabeledDataMapper and instead use vtkVectorText and
> vtkFollower to print 3D text iso-contour labels.
>
>
> Rashed.
>
>
> David Gobbi-3 wrote:
>>
>> The vtkCell subclasses are chock full of unwrappable methods.  I ain't
>> touching them.
>>
>>    David
>>
>>
>> On Wed, May 19, 2010 at 1:15 PM, Jothy <jothybasu at gmail.com> wrote:
>>> Thanks very much!
>>>
>>> Could you please have a look at sometime "PointInPolygon" method in
>>> vtkPolygon. This method is not available in python. I suspect the reason
>>> could be same.
>>>
>>> Thanks again,
>>>
>>> Jothy
>>>
>>> On Wed, May 19, 2010 at 8:11 PM, David Gobbi <david.gobbi at gmail.com>
>>> wrote:
>>>>
>>>> Now in the nightlies: GetNextCell(vtkIdList *pts), GetCell(vtkIdType
>>>> loc, vtkIdList *pts).
>>>>
>>>>  David
>>>>
>>>>
>>>> On Wed, May 19, 2010 at 12:10 PM, Jothy <jothybasu at gmail.com> wrote:
>>>> > Thanks very much. Alert us on the list, when do this.
>>>> >
>>>> > Jothy
>>>> >
>>>> > On Wed, May 19, 2010 at 7:08 PM, David Gobbi <david.gobbi at gmail.com>
>>>> > wrote:
>>>> >>
>>>> >> Hi Jothy,
>>>> >>
>>>> >> The GetNextCell() method's arguments are not wrappable:
>>>> >>
>>>> >>  int GetNextCell(vtkIdType& npts, vtkIdType* &pts);
>>>> >>
>>>> >> Since this same problem has bitten me, too, and since there are no
>>>> >> easy workarounds, I'll add a wrappable method to the nightly VTK:
>>>> >>
>>>> >>  int GetNextCell(vtkIdList *pts);
>>>> >>
>>>> >> This will form a nice symmetry with the InsertNextCell(vtkIdList
>>>> *pts)
>>>> >> method.
>>>> >>
>>>> >>   David
>>>> >>
>>>> >>
>>>> >> On Wed, May 19, 2010 at 11:46 AM, Jothy <jothybasu at gmail.com> wrote:
>>>> >> > Could someone convert it to python. I tried, but it throws some
>>>> error
>>>> >> > at
>>>> >> >
>>>> >> > vtkIdType *indices;
>>>> >> >
>>>> >> >   vtkIdType numberOfPoints;
>>>> >> >   unsigned int lineCount = 0;
>>>> >> >   for (cells->InitTraversal();
>>>> >> >
>>>> >> >        cells->GetNextCell(numberOfPoints, indices);
>>>> >> >        lineCount++)
>>>> >> >
>>>> >> >
>>>> >> >
>>>> >> > Thanks,
>>>> >> >
>>>> >> > Jothy
>>>> >> >
>>>> >> >
>>>> >> >
>>>> >> > On Wed, May 19, 2010 at 1:24 PM, Bill Lorensen
>>>> >> > <bill.lorensen at gmail.com>
>>>> >> > wrote:
>>>> >> >>
>>>> >> >> I've added an example that illustrates one way to place labels on
>>>> >> >> isolines generated by vtkContourFilter.
>>>> >> >>
>>>> >> >> http://vtk.org/Wiki/VTK/Examples/Visualization/LabelContours
>>>> >> >>
>>>> >> >> Bill
>>>> >> >>
>>>> >> >> On Tue, May 18, 2010 at 9:35 PM, rashedk
>>>> <rashed.vtk at googlemail.com>
>>>> >> >> wrote:
>>>> >> >> >
>>>> >> >> > Thanks Bill!  I agree to your T&C :)
>>>> >> >> >
>>>> >> >> >
>>>> >> >> >
>>>> >> >> > rashedk wrote:
>>>> >> >> >>
>>>> >> >> >> Hi all,
>>>> >> >> >>
>>>> >> >> >> vtkContourFilter can draw contours on a dataset, however, is it
>>>> >> >> >> possible
>>>> >> >> >> to label/annotate these contours? I looked at
>>>> >> >> >> vtkLabeledDataMapper
>>>> >> >> >> but
>>>> >> >> >> it
>>>> >> >> >> only seems to label points, cells, etc.
>>>> >> >> >>
>>>> >> >> >> Rashed.
>>>> >> >> >>
>>>> >> >> >
>>>> >> >> > --
>>>> >> >> > View this message in context:
>>>> >> >> >
>>>> http://old.nabble.com/labelling-iso-lines-tp28597889p28603314.html
>>>> >> >> > Sent from the VTK - Users mailing list archive at Nabble.com.
>>>> >> >> >
>>>> >> >> > _______________________________________________
>>>> >> >> > 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
>>>> >> >> >
>>>> >> >> _______________________________________________
>>>> >> >> 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
>>>> >> >
>>>> >> >
>>>> >> > _______________________________________________
>>>> >> > 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
>>>> >> >
>>>> >> >
>>>> >
>>>> >
>>>
>>>
>> _______________________________________________
>> 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
>>
>>
>
> --
> View this message in context: http://old.nabble.com/labelling-iso-lines-tp28597889p28627939.html
> Sent from the VTK - Users mailing list archive at Nabble.com.
>
> _______________________________________________
> 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
>



More information about the vtkusers mailing list