mapeditor / mapeditor/tiled

tmxrasterizer as a git diff tool: override search path, and allow explicitly writing to stdout

Open
#3,867 4 comments 0 reactions 1 assignee View on GitHub

@MollahHamza is already working on this.

Since Mar 9, 2026.

Dominant language
C++
Stars
12.9k
Forks
2k
Avg merge
4h 27m
Merged PRs (30d)
8

Description

Two little features would make it much easier to plug tmxrasterizer into git as a map differ:

  1. An argument for overriding the initial search path. The problem is, when git diffs two versions of the same file, it has to put at least one of them in a temporary file, and now it doesn't know where to find any of its tilesets. I know the original full path, but I have no way to provide it.

  2. Writing the image to stdout. This isn't strictly necessary since tempfiles are always an option, but it did surprise me a little that giving - as the outfile path literally created a file named - :)

With both, I believe you could diff a map against its committed version with a oneliner (in zsh, anyway):

compare -metric PHASH =(tmxrasterizer -s 0.25 -p $(dirname $1) $2 -) =(tmxrasterizer -s 0.25 -p $(dirname $1) $5 -) png:- | display -title "$1" -

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.