The biggest issue in using Leaflet is figuring out how the tiles have to be generated, ordered, and then correctly make the calls so that everything appears as you expect. After a few days hopelessly trying out solution after solution, this was the only one that worked for me, thanks to a tutorial done by Pedro Sousa:
https://build-failed.blogspot.pt/2012/11/zoomable-image-with-leaflet.html
In essence, this uses GDAL2Tiles to correctly split tiles in a predictable way. This is the kind of tool that is easily available on most Linux distributions (and allegedly it runs fine under Mac OS X as well, using ports or a similar thing). There is no watermarking, limitation on size, etc. whatsoever with this tool. Place the tiles on directories of your server just like Pedro Sousa explains in his article.
Leaflet will then load a 'map' using your tiles with 'fake' geo coordinates, using the raster file's size to calculate the 'fake' longitude/latitude correctly. After that, you can pretty much do with it whatever you wish, just like any other map tile server. In my case, I only needed to drop some markers, so I couldn't care less in what coordinate system I was working on — the function below was useful to extract the 'fake' geo coordinates in order to know where to place the markers:
var popup = L.popup();
function onMapClick(e) {
popup
.setLatLng(e.latlng)
.setContent("You clicked the map at " + e.latlng.toString() + "\nZoom level is " + map.getZoom())
.openOn(map);
}
map.on('click', onMapClick);
I did manage to successfully replace an old Flash-based map navigator using Leaflet and basically replicate almost every Flash functionality (even using the same markers and all!). With, of course, the advantage that Leaflet will work on iOS devices