hi, im trying to create a multidimensional array and then pass along a few funcitons.
this is the way i have created, im sure its the correct way of doing it?
// TerrainMapData is struct
TerrainMapData **TerrainData ;
TerrainData = new TerrainMapData *[TerrainWidth];
for( USHORT usLoop = 0; usLoop < TerrainLength; usLoop++ )
{
TerrainData[ usLoop ] = new TerrainMapData[ TerrainWidth ];
}
now i dont know how to pass it correctly?
would you call funcitons that would have this:
void SmoothTerrain( TerrainMapData *&TerrainData );
or would it have to be SmoothTerrain( TerrainMapData **&TerrainData );
also what would you think would be more efficient and quicker to do this?
maybe using a vector list or do it some other way, instead of passing the whole multidimensional array?