Support .json maps and tilesets for tmxrasterizer


(Von) #1

It appears tmxrasterizer can only render .tmx maps with .tsx tilesets. If you try to use it with a .json map it will output

Error while reading "mymap.json":
Not a map file.

Since I work exclusively with .json files I ended up having to temporarily export them to .tmx using Tiled command-line, then call the rasterizer. It works but I found it odd that it wouldn’t support .json files.


(Thorbjørn Lindeijer) #2

Yeah, there is no particular reason that the tmxrasterizer couldn’t load the plugins and support additional map formats, other than that it just hasn’t been implemented yet.

Of course, the name “tmxrasterizer” is pretty clear about which format it was supposed to be used with. :wink:

The same goes for tmxviewer.

Alternatively, we could merge the functionality into the Tiled executable. Especially on macOS but also on Linux (when using AppImage), it is not nice to ship such functionality in separate executables.

I’ve opened the following issue about it: