JakeWharton/madge — pull request #2 by roman-mazur (2013-12-06 19:41:54+00:00)
Title: Attempt to calculate scale value and draw it

Not sure whether it works correctly in all the possible cases, yet you might be interested in looking at this :)

Tree factors are considered for actual scale calculation:
1. current canvas matrix (a deprecated `getMatrix` is used for this, yet it seems to work well for software rendering)
2. bitmap and canvas densities
3. user inputs (`src` and `dst` rectangles)