[Gmsh] How to generate .png files for all .geo files in a directory.

Mark Starnes mark.starnes at fttech.co.uk
Tue Aug 23 10:41:46 CEST 2011


That's great James.  Searching for `Draw' in the manual pointed me to example t8.geo, including rotations too!

Thanks for helping.

Best regards,

Mark.
________________________________________
From: James Zhou [james at shapeways.com]
Sent: 22 August 2011 16:35
To: Mark Starnes
Cc: gmsh at geuz.org
Subject: Re: [Gmsh] How to generate .png files for all .geo files in a directory.

Yes, once you have the mesh created, you can used the Draw and Print command, e.g.

// Generate mesh, set transformation, etc.
Draw;
Print "thumbnail.png";

James

On Mon, Aug 22, 2011 at 10:10 AM, Mark Starnes <mark.starnes at fttech.co.uk<mailto:mark.starnes at fttech.co.uk>> wrote:
Hi everyone,

I have hundreds (well, more) of .geo files and I was wondering if there was a way to
call, from the command line, gmsh such that a two dimensional mesh is created and
the output saved as a .png, for viewing with a thumbnail viewer.  I can create the mesh
from the command line ok, but when I specify an output filename, a mesh is being saved
when I specify .png as the extension.  I think this is the expected behaviour (from reading
the manual).

Is it possible to generate images in this way?

Best regards,

Mark.
_______________________________________________
gmsh mailing list
gmsh at geuz.org<mailto:gmsh at geuz.org>
http://www.geuz.org/mailman/listinfo/gmsh



--
Qingnan (James) Zhou