+
+//------------------------------------------------------------------------
+void ContourExtractData::Fill_lstlstlstVecXY(int iContour, int sizeY)
+{
+ int i,y;
+ double x1,y1,z1,x2,y2,z2;
+ manualBaseModel *manualcontourmodel= lstManConMod[iContour];
+ int nps = manualcontourmodel->GetNumberOfPointsSpline(); // number of points in the spline
+ manualcontourmodel->UpdateSpline();
+ //------------------------------------------------------------------------------------------------------
+
+ for (y=0;y<sizeY;y++)
+ {
+ manualcontourmodel->GetSpline_i_Point(0,&x1,&y1,&z1);
+ x1=x1+0.5; y1=y1+0.5;
+ for (i=1; i<nps; i++)
+ {
+ manualcontourmodel->GetSpline_i_Point(i,&x2,&y2,&z2);
+ x2=x2+0.5; y2=y2+0.5;
+ if ( ((y1<y2)&&(y>=y1)&&(y<=y2)) || ((y1>y2)&&(y>=y2)&&(y<=y1)) || ((int)y1==y) || ((int)y2==y) )
+ {
+ _lstlstlstVecX1[iContour][y].push_back(x1);
+ _lstlstlstVecY1[iContour][y].push_back(y1);
+ _lstlstlstVecX2[iContour][y].push_back(x2);
+ _lstlstlstVecY2[iContour][y].push_back(y2);
+ }
+ x1=x2; y1=y2; z1=z2;
+ } // for i Points in spline
+ } // y
+
+}
+
+void ContourExtractData::InitLstContoursLinesYPoints()
+{
+ // init InInside Optimisation
+ int i;
+
+ _lstlstlstVecX1.clear();
+ _lstlstlstVecY1.clear();
+ _lstlstlstVecX2.clear();
+ _lstlstlstVecY2.clear();
+
+ /* RaC 20-11-09
+ int ext[6];
+ this->imagedata->GetWholeExtent(ext);
+ int sizeY = ext[3]-ext[2]+1;
+ */
+ std::vector<double> vecDouble;
+ std::vector< std::vector<double> > vecVecDouble;
+ for ( i=0 ; i<_sizeImageY ; i++ )
+ {
+ vecVecDouble.push_back( vecDouble );
+ }
+
+ //Fill structure with points
+ int sizeContours = lstManConMod.size();
+ for( i=0 ; i<sizeContours ; i++ )
+ {
+ _lstlstlstVecX1.push_back( vecVecDouble );
+ _lstlstlstVecY1.push_back( vecVecDouble );
+ _lstlstlstVecX2.push_back( vecVecDouble );
+ _lstlstlstVecY2.push_back( vecVecDouble );
+ Fill_lstlstlstVecXY(i,_sizeImageY);
+ }
+
+}
+
+void ContourExtractData::SetScalarRange(double min, double max)
+{
+ scalarRange[0]=min;
+ scalarRange[1]=max;
+}
+
+void ContourExtractData::SetSizeImageY(int pSizeImageY)
+{
+ _sizeImageY=pSizeImageY;
+}