[vtkusers] writing EnSight files - Error: No BlockID was found
Martin Baumann
mailsgetlost at web.de
Mon Jun 19 08:23:36 EDT 2006
Did anyone of you write EnSight files and did not have problems with
BlockID?
Regards, M.B.
Martin Baumann schrieb:
> Hi,
>
> I am trying to save EnSight data files with the following code:
>
> string in_file = "test.asc";
> string out_file = "ensight.ens";
>
> /// **********************************************/
> /// read Legacy-Format variables/
> /// **********************************************/
>
> vtkUnstructuredGridReader* _reader = vtkUnstructuredGridReader::New();
> _reader->SetFileName(in_file.c_str());
> _reader->Update();
>
>
> /// **********************************************/
> /// write EnSight/
> /// **********************************************/
>
> vtkEnSightWriter* _ens_writer = vtkEnSightWriter::New();
>
> _ens_writer->SetFileName(out_file.c_str());
> _ens_writer->SetInput(_reader->GetOutput());
> _ens_writer->Write();
> _ens_writer->WriteCaseFile(1);
>
>
>
> When I run this I get the error
> No BlockID was found
> for some some hundred times.
>
> Still threee files are created:
> ensight.0.case
> ensight.0.00000.geo
> ensight.0.00000_n.u_x
>
> - I tried to find out what the error means. What are BlockIDs used for?
> - Is there any information on writing EnSight files with vtk?
> - In the example file (test.asc) there are contained three scalars:
> u_x, u_y and u_z.
> Only one (u_x) is written to an EnSight data file. I need to export
> all of the
> scalars and vectors if there are any in the input file. How can I do this?
>
> Regards, M.B.
>
>------------------------------------------------------------------------
>
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>Follow this link to subscribe/unsubscribe:
>http://www.vtk.org/mailman/listinfo/vtkusers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060619/57455591/attachment.htm>
More information about the vtkusers
mailing list