Currently I'm duplicating positions for different input values for same position. For instance consider a CUBE; cube has 8 unique positions, and 24 normals. So we have single INDEX/ELEMENT ARRAY in GL.
Assume that COLLADA gives two different index for describe POSITION and NORMAL indices e.g.:
1 0 2 0 3 0 1 1 4 1 2 1 ...
During parsing I'm converting this indices (<p>) to: ( by duplicating positions )
1 2 3 4 5 6 ...
In the end, I'm making 8 positions to 24 then send GPU,
Currently I'm duplicating positions for different input values for same position. For instance consider a CUBE; cube has 8 unique positions, and 24 normals. So we have single INDEX/ELEMENT ARRAY in GL.
Assume that COLLADA gives two different index for describe POSITION and NORMAL indices e.g.:
1 0 2 0 3 0 1 1 4 1 2 1 ...
During parsing I'm converting this indices (<p>) to: ( by duplicating positions )
1 2 3 4 5 6 ...
In the end, I'm making 8 positions to 24 then send GPU,
Maybe there are better way to do this?