Skip to content
Snippets Groups Projects
Select Git revision
  • 1f58a04887353c62aee188496874e5046e0218f2
  • master default
  • cgnsUnstructured
  • partitioning
  • poppler
  • HighOrderBLCurving
  • gmsh_3_0_4
  • gmsh_3_0_3
  • gmsh_3_0_2
  • gmsh_3_0_1
  • gmsh_3_0_0
  • gmsh_2_16_0
  • gmsh_2_15_0
  • gmsh_2_14_1
  • gmsh_2_14_0
  • gmsh_2_13_2
  • gmsh_2_13_1
  • gmsh_2_12_0
  • gmsh_2_11_0
  • gmsh_2_10_1
  • gmsh_2_10_0
  • gmsh_2_9_3
  • gmsh_2_9_2
  • gmsh_2_9_1
  • gmsh_2_9_0
  • gmsh_2_8_6
26 results

drawGlyph.cpp

Blame
  • Forked from gmsh / gmsh
    Source project has a limited visibility.
    LuaBindings.cpp 12.64 KiB
    // Gmsh - Copyright (C) 1997-2010 C. Geuzaine, J.-F. Remacle
    //
    // See the LICENSE.txt file for license information. Please report all
    // bugs and problems to <gmsh@geuz.org>.
    //
    // Contributor(s):
    //   Jonathan Lambrechts
    //
    
    #include "GmshConfig.h"
    
    #if defined(HAVE_LUA)
    #include <iostream>
    #include <string>
    #include "Gmsh.h"
    #include "Context.h"
    #include "MVertex.h"
    #include "MElement.h"
    #include "GFace.h"
    #include "DivideAndConquer.h"
    #include "Bindings.h"
    #include "luaFunction.h"
    #include "function.h"
    #include "GModel.h"
    #include "Bindings.h"
    #include "GmshMessage.h"
    #include "linearSystem.h"
    
    #if defined(HAVE_OPENGL)
    #include "drawContext.h"
    #endif
    
    #if defined(HAVE_SOLVER)
    #include "linearSystemCSR.h"
    #endif
    
    extern "C" {
    #include "lua.h"
    #include "lualib.h"
    #include "lauxlib.h"
    }
    
    #if defined(HAVE_READLINE)
    #include "readline.h"
    #include "history.h"
    #endif
    
    //trivial class to bind options
    class gmshOptions {
      public:
      gmshOptions(){}
      void colorSet(std::string category, int index, std::string name, int value)
      {
        GmshSetOption(category, name, (unsigned int)(value), index);
      }
      int colorGet(std::string category, int index, std::string name)
      {
        unsigned int value;
        GmshGetOption(category, name, value, index);
        return value;
      }
      double numberGet(std::string category, int index, std::string name)
      {
        double value;
        GmshGetOption(category, name, value, index);
        return value;
      }
      void numberSet(std::string category, int index, std::string name, double value)
      {
        GmshSetOption(category, name, value, index);