I'll think it'll be fast enough to use for positioning units right? As long as I only run the first line before I start main loop and then use only the second line often (accessing files is rather slow i've learned)
You just need to be weary of the scaling of the terrain. If the terrain scale is 1, 1, 1, then pixel 500,500 is game unit 500,500. However, if you scale your terrain, you'll have to keep multiply scale of the terrain by the position from the heightmap to get the same game unit.