MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0022857Open CASCADE[OCCT] OCCT:VISpublic2011-12-16 16:482014-11-11 12:58
Reportersan 
Assigned Tobugmaster 
PrioritynormalSeverityminor 
StatusclosedResolutionfixed 
PlatformAOSLOS VersionL
Product Version 
Target Version[OCCT] 6.8.0Fixed in Version[OCCT] 6.8.0 
Summary0022857: Method to activate selection mode for a given IVtk_IShape
DescriptionMethod to (de-)activate selection mode for a given IVtk_IShape is missing in IVtkTools_ShapePicker class. Maybe it makes sense to "duplicate" IVtk_IShapePickerAlgo API in this regard.
TagsNo tags attached.
Test case numberNot needed
Attached Files

- Relationships
related to 0024904closedbugmaster Visualization - Integration of VIS component 

-  Notes
(0018900)
rkv (developer)
2011-12-19 11:15

I'd suggest the following signature with vtkActor as a shape representation parameter:
  //! Turn on/off a selection mode for a shape actor.
  //! @param [in] shapeActor shape presentation actor to set a selection mode for
  //! @param [in] mode selection mode to be activated
  //! @param [in] turnOn Flag to turn on/off the selection mode
  void setSelectionMode (vtkActor* shapeActor,
                         const IVtk_SelectionMode mode,
                         const bool turnOn = true);
(0018908)
san (developer)
2011-12-19 14:30

Roman,

Your proposal looks good.
I would recommend adding a second overloaded setSelectionMode() that would accept IVtk_IShape instance, to let application developers choose whether to work with VTK classes (actors) or VIS classes (IShape interface).
(0018910)
rkv (developer)
2011-12-19 15:18

Following methods has been added for IVtkTools_ShapePicker:

  //! Turn on/off a selection mode for a shape actor.
  //! @param [in] shapeActor shape presentation actor to set a selection mode for
  //! @param [in] mode selection mode to be activated
  //! @param [in] turnOn Flag to turn on/off the selection mode
  void SetSelectionMode (IVtk_IShape::Handle& shape,
                         const IVtk_SelectionMode mode,
                         const bool turnOn = true) const;

  //! Turn on/off a selection mode for a shape actor.
  //! @param [in] shapeActor shape presentation actor to set a selection mode for
  //! @param [in] mode selection mode to be activated
  //! @param [in] turnOn Flag to turn on/off the selection mode
  void SetSelectionMode (vtkActor* shapeActor,
                         const IVtk_SelectionMode mode,
                         const bool turnOn = true) const;
(0018911)
san (developer)
2011-12-19 15:35

void SetSelectionMode (IVtk_IShape::Handle& shape,
                         const IVtk_SelectionMode mode,
                         const bool turnOn = true) const;

Normally, if an input argument is passed by reference, a const reference should be used. Thus const IVtk_IShape::Handle& shape should appear above.
(0018913)
san (developer)
2011-12-19 15:46

Non-const references should be used for output arguments only.
(0018914)
rkv (developer)
2011-12-19 15:46
edited on: 2011-12-19 15:47

Fixed for shape parameter.

(0021269)
san (developer)
2012-08-18 14:41

The issues was created during development of VIS component for development needs only.
The issue has been corrected and should be closed, no testing is required.

- Issue History
Date Modified Username Field Change
2011-12-16 16:48 san New Issue
2011-12-16 16:48 san Assigned To => rkv
2011-12-16 16:48 san Status new => assigned
2011-12-19 11:15 rkv Note Added: 0018900
2011-12-19 11:15 rkv Assigned To rkv => san
2011-12-19 11:15 rkv Status assigned => feedback
2011-12-19 14:30 san Note Added: 0018908
2011-12-19 14:30 san Status feedback => assigned
2011-12-19 14:30 san Assigned To san => rkv
2011-12-19 15:18 rkv Note Added: 0018910
2011-12-19 15:18 rkv Status assigned => resolved
2011-12-19 15:35 san Note Added: 0018911
2011-12-19 15:36 san Status resolved => assigned
2011-12-19 15:46 san Note Added: 0018913
2011-12-19 15:46 rkv Note Added: 0018914
2011-12-19 15:46 rkv Status assigned => resolved
2011-12-19 15:47 rkv Note Edited: 0018914 View Revisions
2011-12-26 07:39 abv Project Open CASCADE => Internal
2012-05-12 17:34 mkv Assigned To rkv => san
2012-08-18 14:41 san Note Added: 0021269
2012-08-18 14:41 san Assigned To san => bugmaster
2012-08-18 14:41 san Status resolved => reviewed
2014-09-18 09:50 abv Target Version => 6.8.0
2014-09-18 09:58 abv Category PRODUCTS:VIS => OCCT:VIS
2014-09-18 10:39 bugmaster Project Internal => Open CASCADE
2014-09-22 11:38 apn Test case number => Not needed
2014-09-22 11:38 apn Assigned To bugmaster => san
2014-09-22 11:38 apn Status reviewed => closed
2014-09-22 11:38 apn Resolution open => fixed
2014-09-22 13:15 apn Assigned To san => bugmaster
2014-09-22 13:15 apn Status closed => feedback
2014-09-22 13:15 apn Status feedback => tested
2014-09-22 13:15 apn Status tested => verified
2014-09-22 13:15 apn Relationship added related to 0024904
2014-11-11 12:45 aiv Fixed in Version => 6.8.0
2014-11-11 12:58 aiv Status verified => closed


Copyright © 2000 - 2020 MantisBT Team
Powered by Mantis Bugtracker