---

wait, why do you want to use 16 bpp, or multi channel ? Do you have any specific purposes ? Or you just follow that algo ?
If only for heightfield, 8 bpp (1 channel) grayscale is enough.
same link