[Gmsh] howto import STEP/IGES/BREP file?

Christophe Geuzaine cgeuzaine at ulg.ac.be
Tue Feb 19 18:40:59 CET 2008


Edgar Last wrote:
> Thanks for the solutions how to configure gmsh with opencascade support 
> and how to import a STEP file.
> 
> Now I wonder how I can set the characteristic lengths in an imported 
> geometry. Is there no documentation how to use the import feature? I 
> will probably have many more questions about what shapes can be meshed, 
> mesh control etc. Do I need to take the source code for the only 
> "documentation"?

Using a nightly snapshot, you have many options:

1) Specify a global scaling factor (using e.g. "-clscale" on the command 
line). When no char. lengths are provided (which is the case when you 
load a normal STEP file), a default length of "object_size/10" is used. 
Using "-clscale 0.1" will divide this default length by 10.

2) Specify a min and/or a max char. length, using the "-clmin" and 
"-clmax" command line options.

3) Compute the char. length automatically from the curvatures, using 
"-clcurv".

4) Use a background mesh (see tutorial/t7.geo).

5) Merge your STEP file in a GEO file, and use all the char. length 
modification options available in the .geo language. In addition to the 
  options given above (for example, 
"Mesh.CharacteristicLengthFactor=0.1;" in a GEO file  is the same as 
"-clscale 0.1" on the command line), you have also full access to char. 
lengths associated with points, function-based size fields, etc.



> 
> Btw, I am now using the precompiled gmsh version from the gmsh website, 
> which is fine for the moment. The configure options you suggested didn't 
> have any effect. I used:
> ./configure --enable-occ --with-occ-prefix=/opt/local/opencascade
> Configure produced no output at all mentioning occ, is this to be 
> expected? Compilation was successful, but no import possible. This is 
> not a severe problem right now, because I can use the precompiled 
> binary. However, I'd like to be able to compile with occ support. How 
> can I find out why configure doesn't recognize occ?
> 
> Edgar
> 
> ------------------------------------------------------------------------
> Express yourself instantly with MSN Messenger! MSN Messenger 
> <http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/>
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> gmsh mailing list
> gmsh at geuz.org
> http://www.geuz.org/mailman/listinfo/gmsh


-- 
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science
http://www.montefiore.ulg.ac.be/~geuzaine