// bbSetOutputOut( bbGetInputIn() );
// std::cout << "Output value = " <<bbGetOutputOut() << std::endl;
-
if (bbGetInputImage()!=NULL)
{
-
manualpaintmodel->SetActive( bbGetInputActive() );
manualpaintmodel->SetTool( bbGetInputTool() );
manualpaintmodel->Set2D3D( bbGetInput2D3D() );
manualpaintmodel->SetDistanceFill( bbGetInputDistanceFill() );
manualpaintmodel->SetRangeMin( bbGetInputRange()[0] );
manualpaintmodel->SetRangeMax( bbGetInputRange()[1] );
-
if (bbGetInputPoint().size()==3)
{
manualpaintmodel->PaintImage( bbGetInputPoint()[0] , bbGetInputPoint()[1] , bbGetInputPoint()[2] );
} // if Points
-
-
-
if ( bbGetInputByLstPointsX().size()!=0 )
{
int i,size = bbGetInputByLstPointsX().size();
manualpaintmodel->PaintImage( bbGetInputByLstPointsX()[i] , bbGetInputByLstPointsY()[i] , bbGetInputByLstPointsZ()[i] );
} // for
}// if ByLstPointsX
-
- if (bbGetInputByImagePoints()!=NULL)
+ if ((bbGetInputByImagePoints()!=NULL) && (bbGetInputImage2()!=NULL) )
{
// int ia,ja,ka;
// int ii,jj,kk;
#else
bbGetInputByImagePoints()->GetExtent(ext);
#endif
-
int dimX=ext[1]-ext[0]+1;
int dimY=ext[3]-ext[2]+1;
int dimZ=ext[5]-ext[4]+1;
-
DEF_POINTER_IMAGE_VTK_CREA(vBIP,sSBIP,pBIP,sTBIP,bbGetInputByImagePoints());
DEF_POINTER_IMAGE_VTK_CREA(vI2,sSI2,pI2,sTI2,bbGetInputImage2());
-
//#pragma omp parallel for
-
int i,j,k;
for (k=0;k<dimZ;k++)
{
}// for i
}// for j
}// for k
-
printf("ManualPaint_Model %d%\n", 100 );
} // if ByImagePoints
-
-
-
} else {
- printf("EED Warning: Image not set. Box creaMaracasVisu::ManualPaint_Model (BBTK) \n");
- } // if bbGetInputImage()
-
+ printf("EED Warning: ByImagePoints or Image2 not set. Box creaMaracasVisu::ManualPaint_Model (BBTK) \n");
+ } // if ((bbGetInputByImagePoints()!=NULL) && (bbGetInputImage2()!=NULL) )
if (bbGetInputImage2()!=NULL)
{
} else {
bbSetOutputOut( NULL );
}
-
}
//=====
// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
// Here we initialize the input 'In' to 0
bbSetInputActive(true);
- bbSetInputTool(1); // Paint
- bbSetInput2D3D(1); // 3D
+ bbSetInputTool(1); // Paint
+ bbSetInput2D3D(1); // 3D
bbSetInputImage(NULL);
bbSetInputImage2(NULL);
bbSetInputGrayLevel(100);
- bbSetInputDirection(2); // XY
+ bbSetInputDirection(2); // XY
bbSetInputBrushSize(3);
- bbSetInputBrushForm(1); // sphere
+ bbSetInputBrushForm(1); // sphere
bbSetInputToleranceFill(50);
bbSetInputDistanceFill(25);
-
std::vector<int> point;
point.push_back(0);
point.push_back(0);
point.push_back(0);
bbSetInputPoint(point);
-
std::vector<double> range;
range.push_back(0);
range.push_back(200);
bbSetInputRange(range);
-
bbSetInputByImagePoints(NULL);
-
}
//=====
// Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
//---------------------------------------------------------------------------
void FillFilter::SetImages(vtkImageData *image,vtkImageData *image2) // virtual
-{
-
-
- baseFilterManualPaint::SetImages(image,image2);
-
+{
+ baseFilterManualPaint::SetImages(image,image2);
if ((_maxX!=_maxXback) || (_maxY!=_maxYback) || (_maxZ!=_maxZback))
{
if (_auxImageFill != NULL)
ivi = _px + _py*(_maxX+1) + _pz*(_maxX+1)*(_maxY+1); // index vector image
-
DEF_POINTER_IMAGE_VTK_CREA_set(v_image,ss_image,p_image,st_image,_image)
-DEF_POINTER_IMAGE_VTK_CREA_set(v_image2,ss_image2,p_image2,st_image2,_image2)
-
-
+if (_image2!=NULL)
+{
+ DEF_POINTER_IMAGE_VTK_CREA_set(v_image2,ss_image2,p_image2,st_image2,_image2)
+}
//EED01
// FillToolRecursive(_px, _py, _pz);
FillToolRecursive(_px, _py, _pz, ivi);
-
unsigned char *pImage;
pImage = (unsigned char *) _auxImageFill->GetScalarPointer();
int ii, jj, kk;
ivi = 0;
+
while (_countRecursiveFillProblem != 0)
{
_countRecursiveFillProblem = 0;