using vtkgdcm;
public class HelloVTKWorld
{
public static int Main(string[] args)
{
string filename = args[0];
reader.SetFileName( filename );
reader.Update();
vtkMedicalImageProperties prop = reader.GetMedicalImageProperties();
System.Console.WriteLine( prop.GetPatientName() );
if( reader.GetImageFormat() == vtkgdcm.vtkgdcm.VTK_LUMINANCE )
{
System.Console.WriteLine( "Image is MONOCHROME2" );
}
vtkMatrix4x4 dircos = reader.GetDirectionCosines();
dircos.Invert();
string outfilename = args[1];
writer.SetShift( reader.GetShift() );
writer.SetScale( reader.GetScale() );
writer.SetImageFormat( reader.GetImageFormat() );
writer.SetFileName( outfilename );
writer.SetInputConnection( reader.GetOutputPort() );
return 0;
}
}
Definition vtkGDCMImageReader.h:105
static vtkGDCMImageReader * New()
Definition vtkGDCMImageWriter.h:50
static vtkGDCMImageWriter * New()
virtual void SetMedicalImageProperties(vtkMedicalImageProperties *)
virtual void SetDirectionCosines(vtkMatrix4x4 *matrix)