[Paraview] Ensight Files - crash with 3.10 and 3.12
Yvan Fournier
yvan.fournier at free.fr
Wed Dec 14 17:19:30 EST 2011
Hello,
I'll let the ParaView developpers confirm this, but this is almost
definitely a bug in OpenFoam, not ParaView.
The error message says it all: some faces are not oriented correctly. I
had already encountered this bug a few years ago when testing The
OpenFoam meshing output with another CFD code, which can read EnSight
fold files, but as I was only running quick tests and had other issues,
I forgot to send a bug report to its developpers (sorry).
The issue is as follows: the EnSight Gold format specifies that nfaced
(polyhedron) elements are defined by their faces (polygons), with
normals pointing outwards (with normals defined in the "trigonometric"
sense. As faces in the OpenFoam structure are shared by 2 cells, their
normal points inwards for 1 of every 2 cells. Correct EnSight Gold
output would thus require that a face's vertices order be reversed
when outputting it to EnSight if that face's normal points inwards,
but in OpenFoam's "conversion/ensight/ensightPartCells.C" file, there
only seems to be a loop on faces, with an inner loop on face vertices,
an no orientation check.
Now the reason things "seemed" to work prior to ParaView 3.8 is that
there was no true polyhedron support, so the reader just wrote polyhedra
as convex point sets. This would produce some display artifacts, but at
least allowed reading EnSight files with polyhedra (that patch was
submitted to Kitware, between ParaView 3.4 and 3.6 if I remember
correctly). As convex point sets have no notion of orientation, the
incorrect output from OpenFoam was not an issue.
With version 3.10, true polyhedra support has arrived, and the readers
have been updated, so things look nicer, but the readers are stricter
regarding the file format.
In any case, with another code doing things as required by the
EnSight documentation, polyhedron support works pretty well with
both ParaView 3.10 and 3.12.
Best regards,
Yvan
> Message: 4
> Date: Sat, 03 Dec 2011 09:45:58 +0100
> From: Fabian Braennstroem <f.braennstroem at gmx.de>
> Subject: [Paraview] Ensight Files - crash with 3.10 and 3.12
> To: paraview at paraview.org
> Message-ID: <4ED9E1C6.8080307 at gmx.de>
> Content-Type: text/plain; charset=ISO-8859-15; format=flowed
>
> Hello,
>
> I have a problem with Ensight files created by OpenFOAM.
> Paraview crashs as soon as I try to create a slice directly after
> loading the file... but only for version 3.10 and 3.12, but it
> works for 3.8.
>
> fbraenns at elephant:
> /data2/WORK/fbraenns/R2N/CFD/Saloon/VI2N_VI1N/M02_B03_G07_OF__Mesh_82Mio_Case1
> $ pv12
> Find an unexpected case. The input polyhedron cell may not be a water
> tight or the polygonal faces may not be planar. Contouring will
> continue, but this cell may not be processed correctly.
> Qt has caught an exception thrown from an event handler. Throwing
> exceptions from an event handler is not supported in Qt. You must
> reimplement QApplication::notify() and catch all exceptions there.
>
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
> Aborted
> fbraenns at elephant:
> /data2/WORK/fbraenns/R2N/CFD/Saloon/VI2N_VI1N/M02_B03_G07_OF__Mesh_82Mio_Case1
> $ pv10
> Qt has caught an exception thrown from an event handler. Throwing
> exceptions from an event handler is not supported in Qt. You must
> reimplement QApplication::notify() and catch all exceptions there.
>
> terminate called after throwing an instance of 'std::bad_alloc'
> what(): std::bad_alloc
> Aborted
>
> As written this does not happen with the 3.8. version.
> Do you have an idea?
>
> Best Regards
> Fabian
More information about the ParaView
mailing list