Skip to content
Snippets Groups Projects
Select Git revision
  • c0419ebe62d6db55f8f76dff4d8194f206197d01
  • master default protected
  • overlaps_tags_and_distributed_export
  • overlaps_tags_and_distributed_export_rebased
  • relaying
  • alphashapes
  • patches-4.14
  • steplayer
  • bl
  • pluginMeshQuality
  • fixBugsAmaury
  • hierarchical-basis
  • new_export_boris
  • oras_vs_osm
  • reassign_partitions
  • distributed_fwi
  • rename-classes
  • fix/fortran-api-example-t4
  • robust_partitions
  • reducing_files
  • fix_overlaps
  • gmsh_4_14_0
  • gmsh_4_13_1
  • gmsh_4_13_0
  • gmsh_4_12_2
  • gmsh_4_12_1
  • gmsh_4_12_0
  • gmsh_4_11_1
  • gmsh_4_11_0
  • gmsh_4_10_5
  • gmsh_4_10_4
  • gmsh_4_10_3
  • gmsh_4_10_2
  • gmsh_4_10_1
  • gmsh_4_10_0
  • gmsh_4_9_5
  • gmsh_4_9_4
  • gmsh_4_9_3
  • gmsh_4_9_2
  • gmsh_4_9_1
  • gmsh_4_9_0
41 results

gmsh.h

Blame
  • gmsh.h 109.16 KiB
    // Gmsh - Copyright (C) 1997-2019 C. Geuzaine, J.-F. Remacle
    //
    // See the LICENSE.txt file for license information. Please report all
    // issues on https://gitlab.onelab.info/gmsh/gmsh/issues.
    
    #ifndef GMSH_H
    #define GMSH_H
    
    // This file defines the Gmsh C++ API (v4.4).
    //
    // Do not edit it directly: it is automatically generated by `api/gen.py'.
    //
    // By design, the Gmsh C++ API is purely functional, and only uses elementary
    // types from the standard library. See `demos/api' for examples.
    
    #if defined(_MSC_VER) && !defined(_USE_MATH_DEFINES)
    #define _USE_MATH_DEFINES
    #endif
    
    #include <cmath>
    #include <vector>
    #include <string>
    #include <utility>
    
    #define GMSH_API_VERSION "4.4"
    #define GMSH_API_VERSION_MAJOR 4
    #define GMSH_API_VERSION_MINOR 4
    
    #if defined(GMSH_DLL)
    #if defined(GMSH_DLL_EXPORT)
    #define GMSH_API __declspec(dllexport)
    #else
    #define GMSH_API __declspec(dllimport)
    #endif
    #else
    #define GMSH_API
    #endif
    
    namespace gmsh {
    
      // A geometrical entity in the Gmsh API is represented by two integers: its
      // dimension (dim = 0, 1, 2 or 3) and its tag (its unique, strictly positive
      // identifier). When dealing with multiple geometrical entities of possibly
      // different dimensions, the entities are packed as a vector of (dim, tag)
      // integer pairs.
      typedef std::vector<std::pair<int, int> > vectorpair;
    
    }
    
    namespace gmsh { // Top-level functions
    
      // Initialize Gmsh. This must be called before any call to the other functions in
      // the API. If `argc' and `argv' (or just `argv' in Python or Julia) are
      // provided, they will be handled in the same way as the command line arguments
      // in the Gmsh app. If `readConfigFiles' is set, read system Gmsh configuration
      // files (gmshrc and gmsh-options).
      GMSH_API void initialize(int argc = 0, char ** argv = 0,
                               const bool readConfigFiles = true);
    
      // Finalize Gmsh. This must be called when you are done using the Gmsh API.
      GMSH_API void finalize();
    
      // Open a file. Equivalent to the `File->Open' menu in the Gmsh app. Handling of
      // the file depends on its extension and/or its contents: opening a file with
      // model data will create a new model.
      GMSH_API void open(const std::string & fileName);
    
      // Merge a file. Equivalent to the `File->Merge' menu in the Gmsh app. Handling
      // of the file depends on its extension and/or its contents. Merging a file with
      // model data will add the data to the current model.