MantisBT - VTK
View Issue Details
0011790VTK(No Category)public2011-02-03 04:252013-06-05 16:24
John Stark 
Jean-Christophe Fillion-Robin 
normalminoralways
closedfixed 
Windows XP64
 
5.8 
0011790: vtkBoxWidget2 does not respect interaction filters.
vtkBoxWidget2 has several attributes that would appear from the documentation to control the interaction, namely : TranslationEnabled, ScalingEnabled and RotationEnabled. However, when I set some these to false, I see no change in the available interactions.
// Requires this input :
// vtkImageData * image;
// And these to display :
// vtkRenderWindowInteractor * iren;
// vtkRenderer * ren;

    typedef vtkSmartPointer<vtkBoxWidget2> vtkBoxWidget2Pointer;
    typedef vtkSmartPointer<vtkBoxRepresentation> vtkBoxRepresentationPointer;

    vtkBoxRepresentationPointer boxRep (vtkBoxRepresentationPointer::New());
    boxRep->PlaceWidget( image->GetBounds() );
    boxRep->HandlesOn();

    vtkBoxWidget2Pointer boxWidget = vtkBoxWidget2Pointer::New();
    boxWidget->SetInteractor( iren );
    boxWidget->SetRepresentation( boxRep );
    boxWidget->On();
    boxWidget->TranslationEnabledOff();
    boxWidget->ScalingEnabledOff();
    boxWidget->RotationEnabledOn();

    ren->AddViewProp( boxRep );
No tags attached.
Issue History
2011-02-03 04:25John StarkNew Issue
2011-03-15 12:10Eric MonsonNote Added: 0025787
2011-03-16 06:03John StarkNote Added: 0025791
2011-08-10 14:00John BiddiscombeSource_changeset_attached => VTK master dcb7cc21
2013-06-05 16:22Jean-Christophe Fillion-RobinAssigned To => Jean-Christophe Fillion-Robin
2013-06-05 16:22Jean-Christophe Fillion-RobinStatusbacklog => tabled
2013-06-05 16:24Jean-Christophe Fillion-RobinStatustabled => closed
2013-06-05 16:24Jean-Christophe Fillion-RobinResolutionopen => fixed
2013-06-05 16:24Jean-Christophe Fillion-RobinFixed in Version => 5.8

Notes
(0025787)
Eric Monson   
2011-03-15 12:10   
I have a patch up on Gerrit that should address this issue:

http://review.source.kitware.com/#change,1206 [^]

(Sorry, it looks like I didn't catch a few terminal spaces before submitting...)
(0025791)
John Stark   
2011-03-16 06:03   
These changes look good to me, many thanks.