Skip to content
Snippets Groups Projects
  1. Mar 11, 2008
    • Christophe Geuzaine's avatar
      5a182522
    • Christophe Geuzaine's avatar
      *** empty log message *** · 143cab2f
      Christophe Geuzaine authored
      143cab2f
    • Christophe Geuzaine's avatar
      cleanup CTX.files · 4b575910
      Christophe Geuzaine authored
      4b575910
    • Christophe Geuzaine's avatar
      example driver · da71fed9
      Christophe Geuzaine authored
      da71fed9
    • Christophe Geuzaine's avatar
      · 9139fe13
      Christophe Geuzaine authored
      - new GmshInitialize(argc, argv) and GmshFinalize() for library version,
        now also used throughout
      
      - GModel::mesh(dimension)
      
      We now have a simple API to do basic stuff. We'll interface more as we go (optimize, adapt, etc.).
      
      #include <stdio.h>
      #include <gmsh/Gmsh.h>
      #include <gmsh/GModel.h>
      #include <gmsh/MElement.h>
      
      int main(int argc, char **argv)
      {
        GmshInitialize(argc, argv);
        GModel *m = new GModel();
        m->readGEO("./tutorial/t5.geo");
        m->mesh(3);
        for(GModel::riter it = m->firstRegion(); it != m->lastRegion(); ++it){
          printf("volume %d contains %d elements:\n", (*it)->tag(), (*it)->getNumMeshElements());
          for(unsigned int i = 0; i < (*it)->getNumMeshElements(); i++)
            printf(" %d", (*it)->getMeshElement(i)->getNum());
          printf("\n");
        }
        m->writeMSH("test.msh");
        m->writeUNV("test.unv");
        GmshFinalize();
      }
      9139fe13
  2. Mar 10, 2008
  3. Mar 09, 2008
  4. Mar 08, 2008
  5. Mar 07, 2008
  6. Mar 06, 2008
  7. Mar 05, 2008
  8. Mar 04, 2008
  9. Mar 03, 2008
  10. Mar 01, 2008
  11. Feb 27, 2008
  12. Feb 26, 2008
  13. Feb 25, 2008
  14. Feb 24, 2008
  15. Feb 23, 2008
Loading