+
+ if(_currentimg != bbGetInputIn()){
+ _currentimg = bbGetInputIn();
+ //mwxwidget->initializeHistogram(_currentimg);
+ mwxwidget->setImageData(_currentimg);
+ //mwxwidget->Refresh();
+ }
+
+ onColorChange();
+
+ /*bbSetOutputGreyLevel(greylevel);
+ bbSetOutputValue(value);
+ bbSetOutputGreyLevelColors(greylevelcolors);
+ bbSetOutputRed(red);
+ bbSetOutputGreen(green);
+ bbSetOutputBlue(blue);*/
+
+
+
+
+ }
+
+
+}
+
+void TransferFunctionView::onColorChange(){
+
+ std::vector<double> greylevel;
+ std::vector<double> value;
+
+ std::vector<double> greylevelcolors;
+ std::vector<double> red;
+ std::vector<double> green;
+ std::vector<double> blue;
+
+ mwxwidget->GetValuesPointsFunction(greylevel, value);
+ mwxwidget->GetValuesColorPointsFunction(greylevelcolors,red, green,blue);
+
+
+ _tfun->RemoveAllPoints();
+ for(int i = 0; i < greylevel.size();i++){
+ _tfun->AddPoint(greylevel[i], value[i]);
+ std::cout<<"TransferFunctionView::Process()transfer function "<<greylevel[i]<<" "<< value[i]<<std::endl;