Original Post
Ok my first real question...
when i started opengl coding, like 5 months ago, i was wondering how to actually resize an array..
in the nehe tutorials you make structures and then use
sector1.triangles = new TRIANGLE[numtriangles];
now i thought like, why not make the structure sector so it can load more textures..
struct SECTOR
{
int numtriangles;
int numtextures;
TRIANGLE* triangle;
GLuint texture[1];
};
and then use
sector1.trangle = new TRIANGLE[numtriangles];
sector1.texture = new GLuint[numtextures];
but then it gives me this error:
cannot convert from 'struct TRIANGLE *' to 'unsigned int [1]'
:S
GreetS
//edit
oh yes i forgot to mention the basecode is from nehe,
i devided it into pieces, i use main.h to declare for example the structs in!
[edited by - Fluid FX on July 31, 2002 9:36:31 AM]