]> Creatis software - creaMaracasVisu.git/blobdiff - lib/maracasVisuLib/src/interface/wxWindows/widgets/ThresholdImageView/ColorLayerImageView.h
#2651 creaMaracasVisu Feature New Normal - Color Layer: Transparent Base, Refresh
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / ThresholdImageView / ColorLayerImageView.h
index 6126438ffab6457e9fc203cff64a4a9abf71465e..86ceb68b2a00a2367a7ec967a760565609e45073 100644 (file)
@@ -45,7 +45,11 @@ class  ColorLayerImageView : public LayerImageBase
          ColorLayerImageView( );
          ~ColorLayerImageView( );
          void SetSliceFixDynamic(bool fix_dynamic);
+         void SetX2(int x2);
+         void SetY2(int y2);
          void SetZ2(int z2);
+         virtual int GetX();
+         virtual int GetY();
          virtual int GetZ();
          
          /** 
@@ -54,6 +58,11 @@ class  ColorLayerImageView : public LayerImageBase
           * \param base_color the base color vector.
           */
          void SetBaseColors(std::vector<double> & base_color);
+
+
+         void SetBaseTransparence(std::vector<double> & base_transparence);
+
+
          /** 
           * \brief  Returns the base color for a given index (first coordinate of the first color being 1, second coordinate of the first color being 2, etc.).
           *
@@ -87,21 +96,29 @@ class  ColorLayerImageView : public LayerImageBase
           */
          int GetBaseColorNb();
 
+
+               void    FillColorTable(int start, int end, double r1, double g1, double b1, double r2, double g2, double b2, double t1, double t2);
+
+               int     GrayLevel_TO_colorTableIndex( double VALUE );
+
+
   private:
 
-         int _z2;
-         bool _fix_dynamic;
-         void SetDefaultGreyLevelBoundary();
-         void SetDefaultBaseColorAndGreyLevelBoundary();
+         int   _x2, _y2, _z2;
+         bool  _fix_dynamic;
+         void  SetDefaultGreyLevelBoundary();
+         void  SetDefaultBaseColorAndGreyLevelBoundary();
          virtual void ConfigLookupTable();
+     int       maxColorsThresholdTable;
+
 
-         //! Range values in the colored image.
-         double _range[2];
 
          //! Base colors for the overlaid image.
          std::vector<double> _base_color;
          //! Grey level boundaries.
          std::vector<double> _grey_level_boundary;
+         //! Grey level boundaries.
+         std::vector<double> _transparence_level_boundary;
          //! Color type (plain or gradient color).
          bool _color_type;