Web forum is in read-only mode. Login as active registered customer for write access
  Forum Search   New Posts New Posts

fmx WebOsMaps offline

 Post Reply Post Reply
Author
Ruvolo Pietro View Drop Down
New Member
New Member
Avatar

Joined: 03 Jan 2018
Posts: 3
Post Options Post Options   Quote Ruvolo Pietro Quote  Post ReplyReply Direct Link To This Post Topic: fmx WebOsMaps offline
    Posted: 12 Oct 2018 at 9:03pm
Hi all,
I'm new to  this compnent but I developped an Android App (with Dellphi 10.2 Tokyo) that need to sho an offline (no internet use) map of a limited zone (1 square km)

I don't know how to use the a local copy of the map (I have the osm file)

Can anyone please help me?

Thank you


Pietro Ruvolo

Back to Top
Bart Holvoet View Drop Down
TMS Support
TMS Support
Avatar

Joined: 18 May 2010
Posts: 2008
Post Options Post Options   Quote Bart Holvoet Quote  Post ReplyReply Direct Link To This Post Posted: 15 Oct 2018 at 8:38am
Hi,

Please note that there is currently no support for offline maps in TMS WebOSMaps.
Back to Top
Ruvolo Pietro View Drop Down
New Member
New Member
Avatar

Joined: 03 Jan 2018
Posts: 3
Post Options Post Options   Quote Ruvolo Pietro Quote  Post ReplyReply Direct Link To This Post Posted: 15 Oct 2018 at 10:39am
Hi , Thank you for your answer,
can you at least explain to me how to configure fhe MapOption.TilesURL property in order to read PNG files already on the disk?

Back to Top
Bart Holvoet View Drop Down
TMS Support
TMS Support
Avatar

Joined: 18 May 2010
Posts: 2008
Post Options Post Options   Quote Bart Holvoet Quote  Post ReplyReply Direct Link To This Post Posted: 15 Oct 2018 at 11:45am
Usage of the TileServerUrl property is explained in the PDF manual available from the product page: https://www.tmssoftware.com/site/webosmaps.asp

Note that this property is intended to be used with webserver URLs only. You might want to try if it works with local path as well.
Back to Top
Tsipan Volodymyr View Drop Down
New Member
New Member
Avatar

Joined: 23 Oct 2017
Posts: 3
Post Options Post Options   Quote Tsipan Volodymyr Quote  Post ReplyReply Direct Link To This Post Posted: 21 Dec 2018 at 7:28pm
In fact, there is the way to run TMS WebOSMaps in offline mode.
Of course you need to have your local tile server, but not only.

Developers are decide to stay this kind of strange hardcode inside of component:


  remoteCSS := 'http://openlayers.org/api/theme/default/style.css';
 .....
 remoteJS := 'http://www.tmssoftware.biz/webosmaps/OpenLayers.js';
........
  remoteJS := 'http://openlayers.org/api/OpenLayers.js';
.....
  remoteIMG := 'http://dev.openlayers.org/releases/OpenLayers-2.13.1/img/';

It means, you also need to have your local web-server with support code above, and deceive your operating system like that:

#file hosts
[your_local_web_server] www.tmssoftware.biz
[your_local_web_server] dev.openlayers.org
[your_local_web_server] openlayers.org


I do not understand why the developers did not specify it in the documentation.
Back to Top
Tsipan Volodymyr View Drop Down
New Member
New Member
Avatar

Joined: 23 Oct 2017
Posts: 3
Post Options Post Options   Quote Tsipan Volodymyr Quote  Post ReplyReply Direct Link To This Post Posted: 21 Dec 2018 at 7:30pm
In fact, there is the way to run TMS WebOSMaps in offline mode.
Of course you need to have your local tile server, but not only.

Developers are decide to stay this kind of strange hardcode inside of component:


  remoteCSS := 'http://openlayers.org/api/theme/default/style.css';
  {$IFDEF MSWINDOWS}
  remoteJS := 'http://www.tmssoftware.biz/webosmaps/OpenLayers.js';
  {$ELSE}
  remoteJS := 'http://openlayers.org/api/OpenLayers.js';
  {$ENDIF}
  remoteIMG := 'http://dev.openlayers.org/releases/OpenLayers-2.13.1/img/';


It means, you also need to have your local web-server with support code above, and deceive your operating system like that:

#file hosts
[your_local_web_server] www.tmssoftware.biz
[your_local_web_server] dev.openlayers.org
[your_local_web_server] openlayers.org


I do not understand why the developers did not specify it in the documentation.
Back to Top
Bart Holvoet View Drop Down
TMS Support
TMS Support
Avatar

Joined: 18 May 2010
Posts: 2008
Post Options Post Options   Quote Bart Holvoet Quote  Post ReplyReply Direct Link To This Post Posted: 07 Jan 2019 at 9:10am
Hi,

To use a custom URL for the OpenLayers JS library you can use the MapOptions.ScriptURL property.
Usage of the ScriptURL property is explained in the TMS VCL WebOSMaps PDF manual under the "TWebOSMaps.MapOptions properties" topic.
Back to Top
? ?? View Drop Down
New Member
New Member
Avatar

Joined: 25 Oct 2012
Posts: 18
Post Options Post Options   Quote ? ?? Quote  Post ReplyReply Direct Link To This Post Posted: 06 May 2019 at 3:22am
I think,We can use offline mapping ,you need to download maptile first , save it in your disk, then you can set  TileServerURL by yourself ,i tested it succefull on Windows ,example :
 TMSFMXWebOSMaps1.MapOptions.TileServerURL.Add('file://C:/Users/Administrator/Pictures/map/maptile/googlemaps/hybrid/${z}/${x}/${y}.jpg');
or TMSFMXWebOSMaps1.MapOptions.TileServerURL.Add('C:\\Users\\Administrator\\Pictures\\map\\maptile\\googlemaps\\hybrid\\${z}\\${x}\\${y}.jpg');

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down