[vtkusers] Bug in vtkBMPReader ?
Steve Boyd
skboyd at ucalgary.ca
Fri May 23 19:37:57 EDT 2003
Hi,
It seems to me that the method SetFileNameSliceOffset() is not working
properly. As an example, I want to read in the following series of
bmps:
Al300.bmp
Al301.bmp
...
Al310.bmp
I set extent to [1,256,1,256,300,310] and then run the following code
snippet:
vtkBMPReader *bmps = vtkBMPReader::New();
bmps->SetFilePrefix(filename);
bmps->SetFileNameSliceOffset(300);
bmps->SetFileNameSliceSpacing(1);
bmps->SetFilePattern("%s%.3d.bmp");
bmps->SetDataExtent(extent);
bmps->SetDataSpacing(el_size_mm);
bmps->Allow8BitBMPOn();
As a check that the file name was properly arranged with
SetFilePattern(), I do a check:
bmps->ComputeInternalFileName(300);
cout << "filename: " << bmps->GetInternalFileName() << endl;
The output of this in my command window is:
>> filename: D:\Al600.bmp
Something is work as I think it should read "D:\Al300.bmp", no?
Thanks,
Steve
--
Steven Boyd, PhD
Assistant Professor
Department of Mechanical and Manufacturing Engineering
University of Calgary
2500 University Drive, N.W.
Calgary, Alberta, Canada, T2N 1N4
tel. 1.403.220.4173 fax. 1.403.282.8406 skboyd at ucalgary.ca
-------------------------------------------------------------------
More information about the vtkusers
mailing list