[vtkusers] Disable rotation of vtkBoxWidget2
Eric E. Monson
emonson at cs.duke.edu
Tue May 17 15:04:28 EDT 2011
Hey Matheus,
This functionality was never implemented for some reason. I have a patch sitting on Gerrit, but nobody with commit powers has had a chance to review it yet and see if it is good enough to include in VTK:
http://review.source.kitware.com/#change,1206
If you're using the VTK development head and can figure out how to pull this patch from gerrit, you could try it out. But, I don't know when it will make it into a real VTK release.
-Eric
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
Eric E Monson
Duke Visualization Technology Group
On May 16, 2011, at 12:52 PM, Matheus Brasileiro wrote:
> Hi,
>
> I'm using vtkBoxWidget2 to select a part of something in the scene, but I don't want to let the selection box rotate I just want the Handles (little spheres) able.
> That way I will Just Resize the selection box through the handles.
>
> I try the method vtkBoxWidget2::RotationEnableOff() but it seems not to work.
>
> ..... some part of the code where I create some VTK objects ......
>
> BoxWidget2 = vtkBoxWidget2::New();
> BoxWidget2->SetInteractor(Interactor);
> BoxWidget2->SetRepresentation(BoxRepresentation);
> BoxWidget2->KeyPressActivationOff();
>
> ..... some part of the code where I want to enable the Widget but turn of its rotation .....
>
> BoxRepresentation->OutlineCursorWiresOff();
> BoxRepresentation->OutlineFaceWiresOff();
>
> BoxWidget2->RotationEnableOff(); // this line don't disable the rotation... I still can click on one of the planes of the box and rotate it.
>
> BoxWidget2->On();
> Renderer->Render();
>
> Hope someone can help me.
>
> Best regards.
>
> --
> Matheus Brasileiro Passos
> Engenharia de Controle e Automação
> _______________________________________________
> 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