четверг, 22 октября 2009 г.

Convert TAR files to sqlitedb

Indexing big TAR files is very slow. It is not useful.
Now you can convert you TAR files to sqlitedb format. The sqlitedb files dont need indexing on the android devices.
Use gmv2sqlite for it http://code.google.com/p/robertprojects/downloads/list

Unpak files from the tar file (for example to c:\temp\). Use PeaZip for example.
Write in console: gmv2sqlite.exe c:\temp\
The program will generate c:\temp\rmaps.sqlitedb file

воскресенье, 18 октября 2009 г.

Minimum POI functionality

I mean...
Long tap on the map run context menu. Here you can add POI.
Long tap on the POI icon - edit POI, delete POI.
Tap on the POI icon - show detail tips.
Tap again on the icon - hide the tips.
Use main menu to go to POI list.
Long tap on list item run context menu.
More functionality will come soon...


+ Minimum POI functionality
+ Integration with GPS Status by Rudolf Hornig
+ Move index data of offline maps to sdcard
+ Added buttons for clearing internal cache and index database to preference
+ Update Yandex.Map URL, Google.Map URL
- Bug fix: Wrong compass orientation on landscape mode

+ Минимум функций для добавления точек (POI)
+ Интеграция с GPS Status by Rudolf Hornig. Вызов из меню GPS Status и обратный вызов RMaps
+ Индексные данные оффлайн карт перенесены на sd карту
+ Добавлены в настройки кнопки для очистки внутреннего кэша и индексного файла
+ Обновил URL карт Yandex, Google
- Поправил работу компаса в ландскейп режиме

вторник, 13 октября 2009 г.

Python script to generate an rmaps-compatible sqlitedb

Hi. I wrote a small python script to generate an rmaps-compatible sqlitedb from a directory of tiles. Runs in linux (as opposed to the java-based solution) and takes less memory so it's suitable for large databases.
I used it to generate a topo map of the entire state of Israel. Works well. Anyway, if you have a need for such script, let me know.
Here's the script:

#!/usr/bin/env python
# buildb.py - build an sqlitedb for rmaps from a tree of map tiles.
# (Yoav Weiss)
# Syntax: buildb.py
# should contain a tree of //.png

import sqlite3,sys,os


db.execute("CREATE TABLE tiles (x int, y int, z int, s int, image blob, PRIMARY KEY (x,y,z,s));")

for z in os.listdir(sys.argv[2]):
#if int(z) > maxzoom:
#maxzoom = int(z)
#if int(z) < minzoom:
#minzoom = int(z)
for x in os.listdir(sys.argv[2]+'/'+z):
for y in os.listdir(sys.argv[2]+'/'+z+'/'+x):
db.execute('INSERT INTO "tiles" VALUES(?,?,?,?,?);',(int(x),int(y.split('.')[0]),17-int(z),0,buffer(file("%s/%s/%s/%s" % (sys.argv[2],z,x,y)).read())))

#db.execute("CREATE TABLE info(minzoom,maxzoom);")
#db.execute('INSERT INTO "info" VALUES(?,?);',(minzoom,maxzoom))
db.execute("CREATE TABLE android_metadata (locale TEXT);")
db.execute('INSERT INTO "android_metadata" VALUES("en");')
db.execute('CREATE INDEX IND on tiles (x,y,z,s);')

суббота, 3 октября 2009 г.


+ Поправил Яндекс.Пробки