X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FpPlotter%2FHistogramWidget.h;h=e04bbb150662f63a4bfdf8378b6547ee52ef892c;hb=ae196719490130990cdde501c982c3370b46b21c;hp=078e9efe7d18ff74dc39a9c0c2fe714e04672d83;hpb=3e48d6cf83c4d96585d3e825899db643f9a62193;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramWidget.h b/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramWidget.h index 078e9ef..e04bbb1 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramWidget.h +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter/HistogramWidget.h @@ -24,7 +24,7 @@ #include "pPlotterScaleY.h" #include "pPlotterScaleX.h" -#define MAX 500 +//#define MAX 500 #define NUM_POINTS 100 #define WINDOW_SIZE 10 @@ -39,6 +39,8 @@ public: HistogramWidget( wxWindow *parent, wxWindowID id, const wxPoint &pos, const wxSize &size, int flag,vtkImageData* imageData,int type); + + HistogramWidget( wxWindow *parent, wxWindowID id); ~HistogramWidget(); @@ -134,8 +136,26 @@ public: int getHistogramSize(); void setType(int type); + /** + ** Initialize the histogram + */ + void initializeHistogram(vtkImageData* img); + /** + ** Returns two vectors, the grey level of the point and its value, the value is between [0,1] + **/ + void GetValuesPointsFunction(std::vector& greylevel,std::vector& value); + + /** + ** Returns two vectors, the grey level of the point and its value, the red, green + ** and blue value is between [0,1] + **/ + void GetValuesColorPointsFunction(std::vector& greylevel, + std::vector& red, + std::vector& green, + std::vector& blue); + private: pHistogram* histogram; @@ -150,11 +170,12 @@ private: */ bool transferenceFunctionHasPoints; bool transferenceFunctionHasColor; + wxPanel* getControls(); /* * type=1 with transference function for moving * type=2 without transference function for moving */ - int type; + int type; DECLARE_CLASS(HistogramWidget); //----------------------------------------------------------------------------