[Gmsh] Problem with VTK output

Frederic Dubois frederic.dubois at umontpellier.fr
Wed Apr 17 01:37:20 CEST 2019


Hi, 

If you put at the end of your file (before gmsh.finalize()) the following line 
gmsh.fltk.run() 

You should be able to display your mesh. 

Can you tell me how it is possible to visualize mesh with vtk directly ? 

Regards 

> De: "David Fernández" <david.f.c at live.com>
> À: gmsh at onelab.info
> Envoyé: Mardi 16 Avril 2019 11:13:43
> Objet: [Gmsh] Problem with VTK output

> Hi all,

> I'm using the python interface to run the example "t1.py". I tell it to generate
> a vtk file. The problem is that when I try to open it with Paraview I get the
> following error:

>> Generic Warning: In
>> /home/buildslave/dashboards/buildbot/paraview-pvbinsdash-linux-shared-release_superbuild/build/superbuild/paraview/src/VTK/IO/Legacy/vtkDataReader.cxx,
>> line 1436

>> Error reading ascii data. Possible mismatch of datasize with declaration.

>> ERROR: In
>> /home/buildslave/dashboards/buildbot/paraview-pvbinsdash-linux-shared-release_superbuild/build/superbuild/paraview/src/VTK/IO/Legacy/vtkUnstructuredGridReader.cxx,
>> line 346

>> vtkUnstructuredGridReader (0x924c360): Unrecognized keyword: ,1

> Also, if I try to open with the python vtk module I get:

>> ERROR: In /work/standalone-x64-build/VTK-source/IO/XMLParser/vtkXMLParser.cxx,
>> line 399
>> vtkXMLDataParser (0x5647883f9170): Error parsing XML in stream at line 1, column
>> 1, byte index 1: not well-formed (invalid token)

>> ERROR: In /work/standalone-x64-build/VTK-source/IO/XML/vtkXMLReader.cxx, line
>> 491
>> vtkXMLUnstructuredGridReader (0x5647883fa010): Error parsing input file.
>> ReadXMLInformation aborting.

>> ERROR: In
>> /work/standalone-x64-build/VTK-source/Common/ExecutionModel/vtkExecutive.cxx,
>> line 784
>> vtkCompositeDataPipeline (0x5647882b6da0): Algorithm
>> vtkXMLUnstructuredGridReader(0x5647883fa010) returned failure for request:
>> vtkInformation (0x5647882ba290)
>> Debug: Off
>> Modified Time: 219
>> Reference Count: 1
>> Registered Events: (none)
>> Request: REQUEST_INFORMATION
>> ALGORITHM_AFTER_FORWARD: 1

>> FORWARD_DIRECTION: 0
> This seems strange to me since I'm not changing anything in t1.py except for the
> output format. Does anybody knows what's the reason of this problem?

> I would like to point out that at this point I'm just trying to visualize the
> meshes that I generate, so I would appreciate if you could also let me know of
> alternative "easy" ways to visualize .msh files.

> Thank you very much.

> Best,

> David.

> _______________________________________________
> gmsh mailing list
> gmsh at onelab.info
> http://onelab.info/mailman/listinfo/gmsh

-- 
Frédéric Dubois, PhD, Eng. 
--- 
SRK Consulting, 
Oceanic Plaza, 22nd Floor, 1066 West Hastings Street 
Vancouver, BC, Canada V6E 3X2 
Mobile: +12368650766 
--- 
Directeur adjoint du LMGC, responsable du service ReMICS. 
Laboratoire de Mécanique et Génie Civil - CNRS/UM 
cc 048, 163 rue Auguste Broussonnet, 34090 Montpellier 
http://www.lmgc.univ-montp2.fr/~dubois 
Tel: 33/0 467144984 
Mobile: 33/0 635490843 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://onelab.info/pipermail/gmsh/attachments/20190417/c25d82c8/attachment.html>


More information about the gmsh mailing list