Terrain import auto-levels

2522
10
04-03-2014 09:15 AM
AndreyKushner
New Contributor
Hi there,
I use tiled terrain data because of large size of region. Every height map tile is a 16-bit png texture. So, almost in each texture minimal level is not deep black and maximal level is not deep white. But when I try to import these textures as terrain height map, City Engine adjusts minimal level of every image as deep black and maximal level as deep white. Because of this every terrain has wrong heights. How can I solve it? I think computing of min and max levels of every tile by third-party software is not convenient solution.

Thanks!
0 Kudos
10 Replies
MatthiasBuehler1
Frequent Contributor
Hi,

are the images georeferenced or not ?

CE interprets the grey value and maps it in the elevation range you define, e.g. 0-100. If all images are consistently grey and have the same elevation range, then the heights should all align.

Let me know.

matt
0 Kudos
AndreyKushner
New Contributor
Height maps are refined processed png images of geodata without any additional geo information. In attachment you can see an example of one tile. Full tileset has a range of height from 0 to 1000m. This particular tile has a range from 8 to 300 m. But when I set the range (0,1000) in CE it tries to do auto-level of the height map and adjust the particular height range to the full height range. You can see that this image looks more contrast in preview mode than it is.
0 Kudos
MatthiasBuehler1
Frequent Contributor
Hi,

It's possible this PNG has a color profile it uses. CE does not interpret color profiles ( ignores them ).

Can you try and remove the color profile and try again ?


Let me know ..

Matt
0 Kudos
AndreyKushner
New Contributor
I tried to remove color profile and tried to save the image to different image formats. A result is the same.
I opened this tileset in other programs. It looks correct.
0 Kudos
MatthiasBuehler1
Frequent Contributor
Hi !


I quickly had a chat with one of the developers and it seems that yes, the elevation range is always adapted to the minimal and maximum available values, not pure black and white.

To import realworld data correctly the scaling is calculated internally based on the metadata that always comes with the imagery.

I see the values of 646 (min) and 19458 (max) in your image. But since there's no height/width/unit data available, importing the data correctly is not really possible.

Can you try to get to the source of those images and check if there's a 'world' file available for that data (for png it should be called .pnw) ?

Let me know ..

Matt
0 Kudos
AndreyKushner
New Contributor
Hi Matt,
All is perfect when you download maps from geodata sources and directly use it in City Engine. But these data usually have low resolution and should be refined. For example I use World-Machina software for refining data. When you work with images with third-party editors all geo-information will be lost. So, I think it would be better and more clear for users that  height range is not adapted if there are not any geo-information.

Thanks.
0 Kudos
MatthiasBuehler1
Frequent Contributor
Hi,


Yes, it's a bad thing those third-party editors kill that metadata. Maybe esri tech support (support@esri.com) can help you with getting those edits done by maintaining the metadata in ArcGIS. ( I'm not a GIS expert ).

On the import side, when the georef metadata is not available, CE just falls back to interpreting the imagery as 'standard' images.

Matt
0 Kudos
AndreyKushner
New Contributor
Hi,
Yes, it's a bad thing those third-party editors kill that metadata.
Matt


That's ok, because those software change heights and height range. For example, I create ocean bottom there, so there are "negative" heights in my height map.


On the import side, when the georef metadata is not available, CE just falls back to interpreting the imagery as 'standard' images.
Matt


It's correct behavior, that CE interpret the imagery as "standard". I just think that additional automatic in this process is not necessary and confuse users. May be is it possible to do this feature as optional?

Otherwise I need create additional script which defines height range in every tile.

Thanks.
0 Kudos
MatthiasBuehler1
Frequent Contributor
sure, fair enough .. 🙂

I'll put this on the wishlist.


matt
0 Kudos