[vtkusers] Dicom to jpeg
Jean-Philippe Lebel
jean-philippe.lebel at qc.forintek.ca
Wed Jun 23 09:28:20 EDT 2004
I use the following code to convert a Dicom Image to jpeg but vtk throw
me a "JPEGWriter only supports unsigned char input" error.
Do you know where the problem is? I followed line by line the
vtkJPEGWriter test example.
vtkDICOMImageReader *reader = vtkDICOMImageReader::New();
reader->SetFileName("Images/120");
reader->Update();
vtkJPEGWriter *jpgw1 = vtkJPEGWriter::New();
jpgw1->SetInput(reader->GetOutput());
jpgw1->SetFileName("jpgw1.jpg");
jpgw1->Write();
Jean-Philippe
Forintek Canada Corp.
418-659-2647, ext 3301
jean-philippe.lebel at qc.forintek.ca
More information about the vtkusers
mailing list