[vtkusers] Adding new file formats into VTK

Mathieu Malaterre mathieu.malaterre at kitware.com
Fri May 28 13:28:20 EDT 2004


Tom,

	By MHD, I guess you are not refering to the already existing meta image 
reader for ITK (vtkMetaImageReader), which also had mhd extension.

	Anyway, a few things, right now VTK won't allow you to keep compress 
data -as far as I know- so you'll have to decompress it and then 
populate some VTK dataset structure. Apparently as you describe it it 
seems like a vtkUnstructuredGrid. So you could have for example a look 
at: vtkGAMBITReader which is fairly simple to read/understand.

HTH
Mathieu
Ps: vtkGAMBITReader was also an addition to VTK thanks to one of its 
user: Jean Favre.


tom fogal wrote:
>  <1085686923.15167.51.camel at silverymoon> Berk Geveci writes:
> 
>>What is you data type? Does the reader have to support parallel reading?
>>Streaming?
> 
> 
> "MHD" files. I'm the CS nerd so I let other people worry about it, but it
> seems to me like vectors of magnetic field strengths at various positions,
> written to ASCII-mode files as a series of doubles, plus some other
> miscellaneous data. Final caveat: the data are compressed via a custom
> run-length encoding algorithm.
> 
> Sorry if I'm misunderstanding. Parallel reading as in a multithreaded reader
> or parallel reading as in the data is distributed across a number of nodes
> and I want to congregate / take advantage of that? If it's the former, it
> might be nice; the main issue is speed of data import and if that would help
> considerably than it would be advantageous. If the latter, no this is all
> intended for single-processor workstations which would load all of the data.
> Finally, we've no need for streaming at all.
> 
> Thanks for the help,
> 
> -tom
> 
> 
>>On Thu, 2004-05-27 at 15:26, tom fogal wrote:
>>
>>>Currently our group has external utilities which convert from the file forma
>>
>>t
>>
>>>our models output into VTK's format. Particularly for large datasets, this
>>>causes a great inefficiency, as the data must be read from the disk, 
>>>reformatted in memory, and written back to the disk... and then read back
>>>from disk when VTK loads it.
>>>
>>>We are interested in extending VTK to recognize the file format we are using
>>>to alleviate this excess bottleneck. I was hoping to get some advice on wher
>>
>>e
>>
>>>to start and some sort of vague time estimate from someone who has done this
>>>sort of thing before.
>>>
>>>It looks as if we would want a new object derived from a 'vtkDataSetSource'
>>>which implements a number of functions (*New, vtkTypeRevisionMacro,
>>>PrintSelf, Update, ExecuteInformation, etc...). Am I on the right track?
>>>Is there documentation anywhere which explains the member functions that
>>>would need to be implemented? Is there a particularly 'good'/simple file
>>>reader that we might want to model our code around?
>>>
>>>Thanks,
>>>
>>>-tom
>>>_______________________________________________
>>>This is the private VTK discussion list. 
>>>Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/
>>
>>cgi-bin/vtkfaq>
>>
>>>Follow this link to subscribe/unsubscribe:
>>>http://www.vtk.org/mailman/listinfo/vtkusers
>>
>>-- 
>>Berk Geveci <berklist at nycap.rr.com>
> 
> _______________________________________________
> This is the private VTK discussion list. 
> Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
> 






More information about the vtkusers mailing list