Is there any way to create a multidimetional array with the legnth of 2 variables in c++? Sort of like this:
x = GetImageWidth(HeightMapImage)-2 : y = GetImageHeight(HeightMapImage)-2
// Dim Vertices Array (from 0)
Dim Vertices[x,y] as Vertex
I tried doing this, but it says it needs a constant value
int x = agk::GetImageWidth(heightMapImg) - 2; int y = agk::GetImageHeight(heightMapImg) - 2;
Vertex vertices[x][y];
Then I tried doing this but that didn't work for 2 dimeitional arrays
int x = agk::GetImageWidth(heightMapImg) - 2; int y = agk::GetImageHeight(heightMapImg) - 2;
Vertex vertices = new Vertex[x][y];