[vtkusers] ActiViz | SetFileNames

David Gobbi david.gobbi at gmail.com
Wed Feb 12 10:51:07 EST 2014


Hi Matias,

The vtkDICOMImageReader does not implement the
SetFileNames() method.  That is to say, the method
exists but it does nothing.

The SetDirectoryName() method must be used instead.

  - David


On Wed, Feb 12, 2014 at 8:43 AM, Matias Montroull <matimontg at gmail.com> wrote:
> I guess it was a typo, I meant to say images instead.
>
>
> On Wed, Feb 12, 2014 at 12:32 PM, Bill Lorensen <bill.lorensen at gmail.com>
> wrote:
>>
>> What is arraydeimagenes?
>>
>>
>> On Tue, Feb 11, 2014 at 7:49 PM, Matias Montroull <matimontg at gmail.com>
>> wrote:
>> > Hi,
>> >
>> > I have this code:
>> >
>> >   vtkStringArray images = new vtkStringArray();
>> >
>> > The I do this:
>> >
>> > foreach (string filename in ofdmulti.FileNames)
>> >                     {
>> >      images.InsertNextValue(filename);
>> > }
>> >
>> > then:
>> >
>> >   vtkDICOMImageReader reader = vtkDICOMImageReader.New();
>> >                         reader.SetFileNames(arraydeimagenes);
>> >                         reader.Update();
>> >
>> > And for some reason, the files are not parsed to the reader, I have
>> > this:
>> >
>> > {vtkDICOMImageReader (0C6FB328)
>> >   Debug: Off
>> >   Modified Time: 7101
>> >   Reference Count: 2
>> >   Registered Events: (none)
>> >   Executive: 0C6DECD0
>> >   ErrorCode: NoFileNameError
>> >   Information: 0C707928
>> >   AbortExecute: Off
>> >   Progress: 1
>> >   Progress Text: (None)
>> >   FileName: (none)
>> >   FileNames: 0C6EC430
>> >   FilePrefix: (none)
>> >   FilePattern: %s.%d
>> >   FileNameSliceOffset: 0
>> >   FileNameSliceSpacing: 1
>> >   DataScalarType: short
>> >   NumberOfScalarComponents: 1
>> >   File Dimensionality: 2
>> >   File Lower Left: Off
>> >   Swap Bytes: Off
>> >   DataIncrements: (1, 1)
>> >   DataExtent: (0, 0, 0, 0, 0, 1)
>> >   DataSpacing: (1, 1, 1)
>> >   DataOrigin: (0, 0, 0)
>> >   HeaderSize: 0
>> >   Internal File Name: (none)
>> > DirectoryName : (NULL)
>> > FileName : (NULL)
>> >
>> > And I get this error:
>> > RROR: In
>> > ..\..\..\..\vtksource-prefix\src\vtksource\IO\vtkDICOMImageReader.cxx,
>> > line
>> > 256
>> > vtkDICOMImageReader (0C6FB328): Either a filename was not specified or
>> > the
>> > specified directory does not contain any DICOM images.


More information about the vtkusers mailing list