View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0022854 | Open CASCADE | OCCT:VIS | public | 2011-12-16 14:26 | 2014-11-11 12:58 |
Reporter | Assigned To | bugmaster | |||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Platform | A | OS | L | ||
Target Version | 6.8.0 | Fixed in Version | 6.8.0 | ||
Summary | 0022854: Helper methods in IVtkTools package | ||||
Description | IVtkTools package lacks the following helper methods that should facilitate usage of VIS classes in an application: 1. InitLookupTable() - should return vtkLookupTable instance initialized by standrad OCCT colors used in wireframe mode for different kinds of sub-shapes (free/boundary/shared edges, isolines,...) 2. SetLookupTableColor( vtkLookupTable*, color_role, color ), GetLookupTableColor( vtkLookupTable*, color_role ) - methods to get/modify colors for given type of sub-shapes. 3. InitShapeMapper() - a method to set up the initial shape mapper parameters 4. Maybe, some method to set up the shape actor and/or mapper according to the current display mode. | ||||
Tags | No tags attached. | ||||
Test case number | Not needed | ||||
|
I'd suggest the following methods in IVtkTools namespace: namespace IVtkTools { //! Returns vtkLookupTable instance initialized by standrad OCCT colors used //! in wireframe mode for different kinds of sub-shapes (free/boundary/shared //! edges, isolines,...) IVtkTools_EXPORTS vtkLookupTable* InitLookupTable(); //! Set a color for given type of sub-shapes. IVtkTools_EXPORTS SetLookupTableColor (vtkLookupTable* lut, const IVtk_MeshType colorRole, const double r, const double g, const double b, const double a = 1); //! Get a color for given type of sub-shapes. IVtkTools_EXPORTS GetLookupTableColor (vtkLookupTable* lut, const IVtk_MeshType colorRole, double &r, double &g, double &b); //! Get a color for given type of sub-shapes. IVtkTools_EXPORTS GetLookupTableColor (vtkLookupTable* lut, const IVtk_MeshType colorRole, double &r, double &g, double &b, double &a); //! Set up the initial shape mapper parameters. IVtkTools_EXPORTS InitShapeMapper (vtkMapper* aMapper); } |
|
Following methods are implemented: namespace IVtkTools { //! Returns vtkLookupTable instance initialized by standrad OCCT colors used //! in wireframe mode for different kinds of sub-shapes (free/boundary/shared //! edges, isolines,...) vtkLookupTable* InitLookupTable(); //! Set a color for given type of sub-shapes. //! @param [in,out] aColorTable vtkLookupTable to set the color. //! @param [in] colorRole type of sub-shapes to set the color. //! @param [in] r red color component. Use [0,1] double values. //! @param [in] g green color component. Use [0,1] double values. //! @param [in] b blue color component. Use [0,1] double values. //! @param [in] a the alpha value (the opacity) as a double between 0 and 1. void SetLookupTableColor (vtkLookupTable* aColorTable, const IVtk_MeshType colorRole, const double r, const double g, const double b, const double a = 1); //! Get a color for given type of sub-shapes. //! @param [in] aColorTable vtkLookupTable to set the color. //! @param [in] colorRole type of sub-shapes to set the color. //! @param [out] r red color component as a double between 0 and 1. //! @param [out] g green color component as a double between 0 and 1. //! @param [out] b blue color component as a double between 0 and 1. void GetLookupTableColor (vtkLookupTable* aColorTable, const IVtk_MeshType colorRole, double &r, double &g, double &b); //! Get a color for given type of sub-shapes. //! @param [in] aColorTable vtkLookupTable to set the color. //! @param [in] colorRole type of sub-shapes to set the color. //! @param [out] r red color component as a double between 0 and 1. //! @param [out] g green color component as a double between 0 and 1. //! @param [out] b blue color component as a double between 0 and 1. //! @param [out] a the alpha value (the opacity) as a double between 0 and 1. void GetLookupTableColor (vtkLookupTable* aColorTable, const IVtk_MeshType colorRole, double &r, double &g, double &b, double &a); //! Set up the initial shape mapper parameters with default OCC colors. void InitShapeMapper (vtkMapper* aMapper); //! Set up the initial shape mapper parameters with user colors. //! @param [in,out] aMapper mapper to initialize //! @param [in] aColorTable a table with user's colors definition void InitShapeMapper (vtkMapper* aMapper, vtkLookupTable* aColorTable); } |
|
The issue has been corrected and should be closed, no testing is required. |
Date Modified | Username | Field | Change |
---|---|---|---|
2011-12-16 14:26 |
|
New Issue | |
2011-12-16 14:26 |
|
Assigned To | => rkv |
2011-12-16 14:27 |
|
Status | new => assigned |
2011-12-20 12:49 |
|
Note Added: 0018918 | |
2011-12-20 12:49 |
|
Assigned To | rkv => san |
2011-12-20 12:49 |
|
Status | assigned => feedback |
2011-12-21 10:23 |
|
Note Added: 0018930 | |
2011-12-21 10:24 |
|
Assigned To | san => rkv |
2011-12-21 10:24 |
|
Status | feedback => resolved |
2011-12-21 10:24 |
|
Description Updated | |
2011-12-26 07:39 |
|
Project | Open CASCADE => Internal |
2012-05-12 17:36 |
|
Assigned To | rkv => san |
2012-08-18 14:38 |
|
Note Added: 0021265 | |
2012-08-18 14:38 |
|
Assigned To | san => bugmaster |
2012-08-18 14:38 |
|
Status | resolved => reviewed |
2014-09-18 09:50 |
|
Target Version | => 6.8.0 |
2014-09-18 09:58 |
|
Category | PRODUCTS:VIS => OCCT:VIS |
2014-09-18 10:39 | bugmaster | Project | Internal => Open CASCADE |
2014-09-22 11:36 | apn | Test case number | => Not needed |
2014-09-22 11:36 | apn | Assigned To | bugmaster => san |
2014-09-22 11:36 | apn | Status | reviewed => closed |
2014-09-22 11:36 | apn | Resolution | open => fixed |
2014-09-22 13:12 | apn | Assigned To | san => bugmaster |
2014-09-22 13:12 | apn | Status | closed => feedback |
2014-09-22 13:12 | apn | Status | feedback => tested |
2014-09-22 13:13 | apn | Status | tested => verified |
2014-09-22 13:13 | apn | Relationship added | related to 0024904 |
2014-11-11 12:45 |
|
Fixed in Version | => 6.8.0 |
2014-11-11 12:58 |
|
Status | verified => closed |