fixed bug for 3D where new data was not copied into the right structures