tms_source: added option to change grid origin

<flipy/> in tms source now flips y-axis.
source_tms now supports elevation encoded data as input