[vtkusers] PLEASE HELP - weird behaviour when performing picking using vtkCellPicker

Meisam Aliroteh meisam.aliroteh at gmail.com
Sat Jul 7 19:09:22 EDT 2007


Hi,

I'm really stuck on this issue and seriously need the help of some of you
experts out there. I'm not sure what is causing the problem but I get some
weird behaviour from the vtkCellPicker and I thought somebody out there
might be able to help me. I have a simple program that uses 2 actors to draw
an object. 1st actor is used to draw the object in point-cloud form while
the 2nd actor draws the edges of the object (both actors are rendered at the
same time). I would like to allow the user to pick and move a point or an
edge. I've implemented the program for doing this but there are 2 problems:

1) when the user moves a point or an edge SOMETIME more that half of the
renderer area is erased (i.e nothing is drawn in those areas and I don't see
parts of my object).

2) after moving a few points and edges, the picker starts behaving strangely
and SOMETIME it just doesn't pick anything even though the mouse pointer is
clearly on an object (this happens often). I've debugged the code and I see
that the Pick() method of vtkCellPicker returns 0, indicating that nothing
was picked and I don't understand this, since the mouse pointer is either
over an edge or a point and it should have picked it.

I know I may not have explained the scenario in details so I'm also
providing my C++ code if anyone wants to try it themselves. You can get the
code at http://www.algopro.com/PickerTest/

If you have any idea on how to fix this, please reply to this post.

thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20070707/709f9f2c/attachment.htm>


More information about the vtkusers mailing list