Program: bbtk
Module: $RCSfile: bbvtkImagePlanes.cxx,v $
Language: C++
- Date: $Date: 2008/12/09 12:54:05 $
- Version: $Revision: 1.16 $
+ Date: $Date: 2008/12/15 13:13:47 $
+ Version: $Revision: 1.17 $
=========================================================================*/
/* ---------------------------------------------------------------------
// Initial values : center of the volume (in real world, not in pixels!)
double xSpacing, ySpacing, zSpacing;
bbGetInputIn()->GetSpacing(xSpacing, ySpacing, zSpacing);
-
+
+
bbGetOutputPlaneX()->SetInput(bbGetInputIn());
bbGetOutputPlaneX()->SetPlaneOrientationToXAxes();
bbGetOutputPlaneX()->SetSlicePosition((xMax+xMin)/2.*xSpacing);
Program: bbtk
Module: $RCSfile: bbwxvtkViewer2D.cxx,v $
Language: C++
- Date: $Date: 2008/12/11 15:30:17 $
- Version: $Revision: 1.32 $
+ Date: $Date: 2008/12/15 13:13:49 $
+ Version: $Revision: 1.33 $
Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
l'Image). All rights reserved. See Doc/License.txt or
mDefaultImage = vtkImageData::New();
int dim[3];
- dim[0] = dim[1] = 32 ;
+ dim[0] = dim[1] = 256 ;
dim[2] = 2;
mDefaultImage->SetDimensions ( dim );
mDefaultImage->SetSpacing(1,1,1);
mDefaultImage->SetScalarComponentFromFloat(i,j,k,0,0);
for (int i=0;i<dim[0];i++)
- {
- mDefaultImage->SetScalarComponentFromFloat(dim[0]-i-1,i,0,0,255);
- mDefaultImage->SetScalarComponentFromFloat(i,i,1,0,255);
- }
+ {
+ /*
+ mDefaultImage->SetScalarComponentFromFloat(i,0,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,dim[1]-1,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(0,i,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(dim[0]-1,i,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,0,1,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,dim[1]-1,1,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(0,i,1,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(dim[0]-1,i,1,0,255);
+ */
+ mDefaultImage->SetScalarComponentFromFloat(i,i,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,dim[1]-i-1,0,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,i,1,0,255);
+ mDefaultImage->SetScalarComponentFromFloat(i,dim[1]-i-1,1,0,255);
+ }
backImageData = mDefaultImage;
imageViewer->SetInput( backImageData );