The idea I had in mind was to draw a world map, made with tiles, and then draw everything on a different (and opaque) surface. But to do that this way we would also need a function tile:get_pixels(). This could also be done without tile:get_pixels(), with just a big image drawn in a surface for the world map that is used to compute the pixels of the Mode 7 surface. Maybe there are better ways to do it, but I do not know.
Mode 7 is a bit more complicated, we need a documentation (Edit: Didn't see Diarandor's link)
Because mode 7, afaik, include
- surface slant (angle)
- surface zoom (effects, World map in ALTTP is an example, zoom transition (Final Fantasy))
Importing or making a mode 7 script for Solarus imply a lot of code rewriting, one of which are map, camera, entities, and the list goes on
The solution is to make a DLL (if Lua accept to read a c++ library like RPG Maker does) and make all modif / call scripts from the DLL, so it is more like a module where players choose if they want or not to use Mode7