OpenGL (Open Graphics Library) is a standard specification defining a cross-language, cross-platform API for writing applications that produce 2D and 3D computer graphics.
The interface consists of over 250 different function calls which can be used to draw complex three-dimensional scenes.
OpenGL was developed by Silicon Graphics Inc. (SGI) in 1992 and is widely used in CAD, virtual reality, scientific visualization,information visualization, and flight simulation.
It is also used in video games,where it competes with Direct3D on Microsoft Windows platforms .
OpenGL is managed by a non-profit technology consortium, the Khronos Group.
Introduction to OpenGLES
OpenGL ES (OpenGL for Embedded Systems) is a subset of the OpenGL 3D graphics API designed for embedded devices such as mobile phones, PDAs and video game consoles.
It is defined and promoted by the Khronos Group,a graphics hardware and software industry consortium interested in open
APIs for graphics and multimedia.
The following APIs will provide central understanding in OpenGL & OpenGLES
OpenGL ES offers two primary methods to facilitate drawing:
glVertexPointer: to specify a series of points or
glDrawElements: to draw them using one of the
// Are we using (x,y) or (x,y,z) in each point
// each value is a float value in the buffer
// Between two points there is no space
// pointer to the start of the buffer
glVertexPointer API Definition
glVertexPointer takes native buffer rather than array floats.We need to convert these java-based floats into an accceptable C-like native buffer.We use Java.nio classes to convert float array into native buffer.