OpenGL ES 2 – Tutorial 2 – Draw a Triangle

With “this.objtriangle = new ObjTriangle();” we call the constructor of “ObjTriangle” class where we set the data of our triangle. The vertices of the triangle present in “vertices” and “indices” (written counterclockwise) are not in a format useful for OpenGL, in the constructor they are converted and stored in “vertexBuffer” and “indexBuffer”.

OpenGL ES 2 – Tutorial 2 – Disegnare un Triangolo

Con “this.objtriangle = new ObjTriangle();” richiamiamo il costruttore della classe “ObjTriangle” dove settiamo i dati del nostro triangolo. I vertici del triangolo presenti in “vertices” e “indices” (scritti in senso antiorario) non sono in un formato utile ad OpenGL, nel costruttore vengono converititi e memorizzati in “vertexBuffer” e “indexBuffer”.

OpenGL ES 2 – Tutorial 1 – Basic 2D Project

OpenGL for Embedded Systems (OpenGL ES or GLES) is a subset of the OpenGL computer graphics rendering application programming interface (API) for rendering 2D and 3D computer graphics such as those used by video games, typically hardware-accelerated using a graphics processing unit (GPU). It is designed for embedded systems like smartphones, tablet computers, video game consoles and PDAs.