Testing and bugfixes for heightmap primitive