[vtkusers] writing EnSight files - Error: No BlockID was found

Martin Baumann mailsgetlost at web.de
Fri Jun 16 08:06:19 EDT 2006


  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.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060616/4841e675/attachment.htm>


More information about the vtkusers mailing list