getTriangles = function (face, v) {
                //Work for each element of the array
                if (v + 1 < face.length) {
                    //Add on the triangle variable the indexes to obtain triangles
                    triangles.push(face[0], face[v], face[v + 1]);
                    //Incrementation for recursion
                    v += 1;
                    //Recursion
                    getTriangles(face, v);
                }
                //Result obtained after 2 iterations:
                //Pattern1 => triangle = ["1","2","3","1","3","4"];
                //Pattern2 => triangle = ["1/1","2/2","3/3","1/1","3/3","4/4"];
                //Pattern3 => triangle = ["1/1/1","2/2/2","3/3/3","1/1/1","3/3/3","4/4/4"];
                //Pattern4 => triangle = ["1//1","2//2","3//3","1//1","3//3","4//4"];
            }
Create triangles from polygons by recursion
The best to understand how it works is to draw it in the same time you get the recursion.
It is important to notice that a triangle is a polygon
We get 4 patterns of face defined in OBJ File :
facePattern1 = ["1","2","3","4","5","6"]
facePattern2 = ["1/1","2/2","3/3","4/4","5/5","6/6"]
facePattern3 = ["1/1/1","2/2/2","3/3/3","4/4/4","5/5/5","6/6/6"]
facePattern4 = ["1//1","2//2","3//3","4//4","5//5","6//6"]
Each pattern is divided by the same method
@param face Array[String] The indices of elements
@param v Integer The variable to increment