sysoppl / Cities-Skylines-heightmap-generator

A heightmap generator for Cities: Skylines
https://heightmap.skydark.pl/
172 stars 53 forks source link

Better configurable map export #24

Closed DeznekCZ closed 2 years ago

DeznekCZ commented 2 years ago

Hello sysoppl,

I'm now using your heighmap generator and now I really missing more configurable map export,etc:

Thank you, DeznekCZ

sysoppl commented 2 years ago

image Some of this options are already done. Heightmap will not export road colors or forrest areas - it's only exporting terrain data so later you can add these in game. If you mean something else please explain more. Thanks

DeznekCZ commented 2 years ago

Thanks for this information, I did not see it.

To the point: While exporting a map image, there is no green areas, which are marked on map while browsing, exported. Same issue is with rivers and railroads. On map are not only that, there is also buildings and fields. If there is possible to get any raw data, I can help as programmer to convert them to more complex image for using it as overlay in game. And also higher resolution if possible.

Thanks for answer, DeznekCZ

sysoppl commented 2 years ago

image I exported map image and can see rivers, roads and green areas. I can admit that railroads are not shown. Buildnigs are not shown probably due to zoom - houses are too small to render. Resolution is set here: 2560x2560 and IMO is good enough. IDK if changing it will break it. https://github.com/sysoppl/Cities-Skylines-heightmap-generator/blob/718ddc33c4ecad1773e0238a4eeae0b8582fe399/src/app.js#L609

Because most of the code we are talking about was written by @nonta1234 it will take more time for me to dig into the code, understand it and eventually push new features, which might never happen because of my inexperience in js. In free time I will try to write, test and eventually merge some options as configurable

If there is possible to get any raw data, I can help as programmer to convert them to more complex image for using it as overlay in game.

Code is open source, feel free to dig into it and create PR, I will be happy to merge it!

Thanks

DeznekCZ commented 2 years ago

I tried, that smaller image could be exported (for example 480x480). I will now check if there is different api for OSM.

DeznekCZ commented 2 years ago

I have created an issue which contains solution to get map in OSM format. If you are able to integrate it, will be usefull for players which are using OSM map importer. ISSUE 25 OpenStreetMap Import (WORKSHOP)

nonta1234 commented 2 years ago

Hi I use the Mapbox Static Images API to get map images, but I can't specify the zoom level when getting in the bounding box. I think you need to execute "getStaticImage" directly or another method to get it at the specified zoom level. In addition, the maximum image size is 2560px (1280px @2x) due to the API specifications.

DeznekCZ commented 2 years ago

Hi there, I made something useful but in different language. This tool use OSM map file displays content which can be exported.

Imagege used as overlay: YouTube

If will be someone knowledged in javascript and Java, this may be converted

Thanks DeznekCZ

PS: Application is not runnable without Java SE 16 (link). I'm not able to get link and revert to older version is not easily possible.

sysoppl commented 2 years ago

OSM export is implemented now.