[vtkusers] Selections

Jeff Baumes jeff.baumes at kitware.com
Thu Feb 4 12:23:02 EST 2010


On Thu, Feb 4, 2010 at 10:18 AM, David Doria <daviddoria+vtk at gmail.com> wrote:
>> Hi Jeff,
>> I had tried the AddID function, it also resulted in 0 points in the
>> output. When I added the ::INDICES and ::POINT properties, the output now
>> has 50 points (still supposed to be 11).
>> I see in the Source article you did this:
>> vtkUnstructuredGrid* extracted = extractSelection->GetOutput();
>> but when I try that it tells me cannot convert vtkDataObject to
>> vtkUnstructuredGrid. Hence my vtkDataSet::SafeDownCast. Maybe this is the
>> problem?
>> Here is the latest version:
>> http://www.vtk.org/Wiki/VTK/Examples/ExtractSelection
>> Thanks,
>>
>> David
>
> Any more thoughts on this?
> Thanks,
>
> David

I don't know what's causing the problem, since I don't know if
vtkSelectionSource is messing up or vtkExtractSelection. Some things
I'd try:

1. Inspect vtkSelectionSource output and see if the selection is what
you expected.
2. Try just creating a vtkSelection from scratch and see if that works.

Jeff



More information about the vtkusers mailing list