fem2d_mesh_display_opengl


fem2d_mesh_display_opengl, a C++ code which reads the name of two data files defining a polygonal mesh, reads the data, and displays the mesh using OPENGL.

The files defining the mesh consist of one file containing the coordinates of the points, and a second file that lists the indices of the nodes making up each element. All the elements in the mesh must have the same order, that is, the number of vertices.

Usage:

fem2d_mesh_display_opengl prefix
where prefix is the common filename prefix: reads the node data from nodes.txt, the element data from elements.txt and displays a plot of the mesh.

Licensing:

The information on this web page is distributed under the MIT license.

Languages:

fem2d_mesh_display_opengl is available in a C++ version and a MATLAB version.

Related Data and Programs:

opengl_test, a C++ code which uses opengl() to display graphic images on the screen;

Reference:

  1. Edward Angel,
    Interactive Computer Graphics,
    A Top-Down Approach with OpenGL,
    Addison-Wesley, 2000,
    LC: T385.A514.
  2. Renate Kempf, Chris Frazier, editors,
    OpenGL Reference Manual,
    Addison-Wesley, 1997,
    LC: T385.O642.
  3. Mason Woo, Jackie Neider, Tom Davis,
    OpenGL Programming Guide,
    Addison-Wesley, 1997,
    LC: T385.N435.
  4. Richard Wright, Michael Sweet,
    OpenGL Superbible,
    Waite Group Press, 1996,
    LC: T385.W73.

Source Code:

ELL is an L-shaped region covered by triangles.

RECT is a rectangular region covered by quadrilaterals.

Q4 is a rectangular region covered by quadrilaterals, with a hole.

HEX is a mesh of hexagons.


Last revised on 05 March 2020.