[vtkusers] Highlight vtkBoxWidget face by moving the mouse

Cory Quammen cory.quammen at kitware.com
Mon Dec 21 09:03:06 EST 2015


I don't know exactly how to do what you want, but you might want to take a
look at vtkBoxWidget::HighlightFace(int cellId) for some clues how to do
this.

Hope that helps,
Cory

On Mon, Dec 21, 2015 at 6:31 AM, Amélie Thery <theryame at gmail.com> wrote:

> Hi everyone !
> I am trying to highlight a vtkBoxWidget face, when the mouse position is
> over it, and without picking it.
>
> I have this for the moment :
> case WM_MOUSEMOVE:
>             LPPOINT PT=(LPPOINT)malloc(sizeof(LPPOINT));
>             ::GetCursorPos(PT);
>             vtkSmartPointer<vtkPropPicker>
> picker=vtkSmartPointer<vtkPropPicker>::New();
>             picker->Pick(PT->x, PT->y, 0, this->ren);
>             double* pos = picker->GetPickPosition();
>
> and now I don't know what to do because if I get the actor of the picker,
> the whole BoxWidget comes and I just want the face.
> Any help?
> Thank you,
> Amélie
>
> _______________________________________________
> 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
>
> Search the list archives at: http://markmail.org/search/?q=vtkusers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtkusers
>
>


-- 
Cory Quammen
R&D Engineer
Kitware, Inc.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20151221/d6cc1dee/attachment.html>


More information about the vtkusers mailing list