+#include <iostream>
+
#include <vtkRenderWindowInteractor.h>
#include <vtkImageViewer2.h>
#include <vtkStructuredPoints.h>
int max = ImageViewer->GetWholeZMax();
int slice = (ImageViewer->GetZSlice() + 1 ) % ++max;
ImageViewer->SetZSlice( slice );
- ImageViewer->GetRenderer()->ResetCameraClippingRange();
+ ImageViewer->GetRenderer()->ResetCameraClippingRange();
ImageViewer->Render();
}
}
for(int i=1; i< argc; i++)
reader->AddFileName( argv[i] );
- reader->DebugOn();
+ //reader->DebugOn();
reader->Update();
//print debug info:
}
viewer->SetupInteractor (iren);
-// float *range = reader->GetOutput()->GetScalarRange();
-// viewer->SetColorWindow (range[1] - range[0]);
-// viewer->SetColorLevel (0.5 * (range[1] + range[0]));
+ vtkFloatingPointType *range = reader->GetOutput()->GetScalarRange();
+ viewer->SetColorWindow (range[1] - range[0]);
+ viewer->SetColorLevel (0.5 * (range[1] + range[0]));
// Here is where we setup the observer,
vtkgdcmObserver *obs = vtkgdcmObserver::New();