Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

export map into picture #7813

Closed
mpavlase opened this issue Oct 31, 2019 · 5 comments
Closed

export map into picture #7813

mpavlase opened this issue Oct 31, 2019 · 5 comments

Comments

@mpavlase
Copy link

Hi all,

I've just created a patch (just ugly proof of concept) that do export map into plaintext format + another script to convert that exported format into ordinary bitmap picture (PNG).

Create plain-text export of rail tiles of map:
https://github.com/mpavlase/OpenTTD/tree/map-export

Python script to visualise:
https://github.com/mpavlase/openttd-map-export

@LordAro
Copy link
Member

LordAro commented Nov 2, 2019

Hello! This looks like it could be quite interesting, but unfortunately I can't really tell what it is? How is it a benefit over the existing screenshot facilities (standard, zoomed & whole map)

Rather than exporting to an external file for another tool to interpret, we'd probably want it to write the images directly

@telk5093
Copy link
Contributor

telk5093 commented Nov 2, 2019

It looks like the minimap command which already exists in JGRPP.
(Exporting map into a image file is quite benefit to show to users (via website) how server is going.)

@mpavlase
Copy link
Author

mpavlase commented Nov 2, 2019

Thanks for pointing me to minimap - it basically does the same thing: export map into bitmap. I'm not so skilled in C++, so that's why I used Python to produce actual picture.

My patch persist game projection and main motivation was to get a plan of all rail tiles to be able it print on paper afterwards (in example).

@nielsmh
Copy link
Contributor

nielsmh commented Nov 5, 2019

I think for producing map images and network illustrations a better general approach would be to somehow wrap OpenTTD as a library, so you can use the original code to load and process the map data for whatever purpose, instead of inventing a new file format that would have to be maintained on both producer and consumer end.

@andythenorth
Copy link
Contributor

Thanks for this. Visualising the map in new ways is cool, but it doesn't really relate to the core game :)

Therefore I'm closing it as we try to keep the issue count low for OpenTTD, it helps us focus on things that are important and fun. Feel free to discuss in irc or request re-opening if you disagree. Thanks for contributing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants