<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:verdana,helvetica,sans-serif;font-size:10pt"><div>Thanks a lot! That worked. What I need is for there to be no tolerance AT ALL, regardless of the size of the render window. Is there a fixed value I can set for this effect? I tried zero, and that didnt work.<br><br>- John E<br></div><div style="font-family: verdana,helvetica,sans-serif; font-size: 10pt;"><br><div style="font-family: verdana,helvetica,sans-serif; font-size: 10pt;"><font size="2" face="Tahoma"><hr size="1"><b><span style="font-weight: bold;">From:</span></b> kent williams <nkwmailinglists@gmail.com><br><b><span style="font-weight: bold;">To:</span></b> John Eke <tonee47@yahoo.com><br><b><span style="font-weight: bold;">Cc:</span></b> vtkusers@vtk.org<br><b><span style="font-weight: bold;">Sent:</span></b> Thursday, May 28, 2009 2:32:21 PM<br><b><span style="font-weight:
bold;">Subject:</span></b> Re: [vtkusers] vtkPicker picks an actor that isnt remotely close to the pick point<br></font><br>
the vtkPicker class lets you set the tolerance, for picking. The<br>default tolerance is apparently a bit too loose for your taste.<br><br>From the documentation:<br><br>> virtual void vtkPicker::SetTolerance(double) [virtual]<br>><br>> Specify tolerance for performing pick operation. Tolerance is specified as fraction of rendering window size.<br>> (Rendering window size is measured across diagonal.)<br><br>The way this works is a little squirrelly, because you probably care<br>about a maximum distance from the exact pixel center, in pixels. But<br>this function wants a fraction of the window size (as measured<br>diagonally), which you'll have to compute based on the window<br>geometry. And if your window can be resized, you'll have to watch for<br>resize events and update the picker tolerance.<br><br>But the reason you can pick a few voxels away from the particular<br>voxel is that it's tricky to pick
small features with the mouse<br>pointer. If you set the tolerance too low, it will make it rough for<br>users to pick anything.<br><br>On Thu, May 28, 2009 at 9:02 AM, John Eke <<a ymailto="mailto:tonee47@yahoo.com" href="mailto:tonee47@yahoo.com">tonee47@yahoo.com</a>> wrote:<br>> Hi Guys,<br>><br>> I have a scenario where I am trying to enable annotations on images<br>> displayed in a vtkImageActor. When I click on the image, I place a small<br>> marker at that point on the image. Now when I click on that marker, it<br>> allows me to do other things like enter notes etc.<br>><br>> Problem is, I use vtkPicker to do the pick, and when I click on the marker<br>> it works, problem is I move several pixels AWAY from the marker and when I<br>> attempt a pick, I still pick the same marker. It seems the markers have a<br>> few pixels around them where if you click, you can still pick the actor. IS<br>> there
any way to change this? Are there any params in vtkPicker I can set to<br>> make sure that the markers should ONLY be picked if the intersect DIRECTLY<br>> with the pick point?<br>><br>> Thanks<br>><br>> John E<br>><br>><br>> _______________________________________________<br>> Powered by <a target="_blank" href="http://www.kitware.com">www.kitware.com</a><br>><br>> Visit other Kitware open-source projects at<br><span>> <a target="_blank" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a></span><br>><br>> Please keep messages on-topic and check the VTK FAQ at:<br><span>> <a target="_blank" href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</a></span><br>><br>> Follow this link to subscribe/unsubscribe:<br><span>> <a target="_blank"
href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</a></span><br>><br>><br></div></div></div><br>
</body></html>