3D arrays to 1D pointers & finding locations
I have a 3 dimensional array of locations of objects and would like to put it inot a pointer, but of course you cant do
int*** myarray = new int[x][y][z];
but you have to do this
int* myarray = new int[x*y*z];
how then do i access certain locations of the memory, like location [2][4][1]? You obviously cant do [2*4*1].
help!
-Vulcan
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement