Home »
Archive by category "Intermediate"
We can generate 3D faces from 2D flat images. Using OpenGL this can be challenging, after all it is not a lot more than a primitive triangle rendering API. The technique we will use in this tutorial is very similar, if not nearly identical, to terrain generation in our previous tutorial....
Continue reading »
September 21, 2014 admin Intermediate
In this tutorial we will render terrains. Essentially a terrain is a complex 3d model. It conists of vertexes, faces, texture coordinates, normal vectors etc. Al though it is possible to load complete models such as Wavefront OBJ models, it is generally better to dynamically generate them. First, we...
Continue reading »
September 20, 2014 admin Intermediate
You will need to change the previous code for this tutorial. OpenGL is used to communicate with the Graphical Processing Unit, so by default it does not contain keyboard control. You will need a library to communicate with the keyboard. We can use SDL (which we have been...
Continue reading »
April 23, 2014 admin Intermediate
In this short tutorial we will demonstrate how to do blending in OpenGL. You may notice in the final code we load two different textures: one background texture and one object texture (glass). The background will be a normal square. The cube will blended on top of it,...
Continue reading »
April 23, 2014 admin Intermediate
To create a fire/explosion like effect we can use the same particle engine as in the previous tutorial (starfield) but we have to modify the code a little bit. All particles move upwards; in addition, every particle has to moves at a different speed, and start from the...
Continue reading »
April 23, 2014 admin Intermediate
We introduce a simple particle engine. A particle engine can be used for many purposes in 3d graphics such as fire, explosions, lasers, stars and many other fun things! To make a particle engine, we need to have a particle set. The set consists of N elements...
Continue reading »
April 23, 2014 admin Intermediate