X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FpPlotter%2FHistogramDialogComboBox.h;h=ee5b947e8a7a5b1b9804dd6784dcd95c0dc8db64;hb=9dd39f42ca5abd6ce26dccc8617e5edd30517587;hp=578fdf59ae35d1c4b4cb8ef8402236f1b0c63542;hpb=67508e2c541ebe1a7ab4f3a401fcb8bb53984fc8;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramDialogComboBox.h b/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramDialogComboBox.h index 578fdf5..ee5b947 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramDialogComboBox.h +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramDialogComboBox.h @@ -20,8 +20,11 @@ #include #include "vtkImageData.h" - -#define FILENAME "/Data/colorsfunction.txt" +#ifdef WIN32 +#define FILENAME "/data/colorsfunction.txt" +#else +#define FILENAME "~/.creaMaracasVisu/data/colorsfunction.txt" +#endif class HistogramDialogComboBox : public wxPanel @@ -45,6 +48,9 @@ public: void OnEditBitmapCombo(wxCommandEvent& event); void OnBitmapComboItemSelected(wxCommandEvent& event); + void OnColorLevelChanged(wxCommandEvent& event); + void OnWindowLevelChanged(wxCommandEvent& event); + void setImageData(vtkImageData* img); /** @@ -61,6 +67,9 @@ public: std::vector& green, std::vector& blue); + double GetWindowLevel(); + double GetColorLevel(); + private: std::vector _greyvect; @@ -70,22 +79,28 @@ private: std::vector _greyvecttransfer; std::vector _value; vtkImageData* _img; - int _maxgreyvalue; + double _maxgreyvalue; int _currentitem; /* * Represents the color of the backGround. Default color is the parent color. */ - wxBitmapComboBox* _bitmapcombo; + wxBitmapComboBox* _bitmapcombo; + wxSlider* _slidercolor; + wxSlider* _sliderwindowlevel; std::vector _bitmapsitems; wxBitmap* colorBar_Bitmap; wxSizer* _bitmapsizer; wxSizer* getBitmapCombo(); + wxSizer* getSlidersWlCo(); wxBitmapComboBox* getBitmapComboElements(); void OnLoadComboBoxData(std::vector& itembitmaps,std::string filename); void saveCurrentConfiguration(std::vector& itembitmaps,std::string filename); + void setSlidersValue(); + + };