Re: How to access geotag information?

2010-01-14 Thread Till Harbaum / Lists
Hi,

i just realized that we are talking about completely different things when we 
say geotagged. I am relating to GPS positions. You seem to relate to place 
names. I just learned that the n900 does not write GPS tags. Correct?

Unfortunately that completely spoils the idea to use maep to display these. 
Converting GPS positions into place names and back to coordinates will likely 
cause most images to show up pretty far from their real location and even worse 
will make them all show up at the same place.

Is there a way to enable real GPS tagging? Is there any reason why this isn't 
happending? It's so obvious that just i didn't expect this not to be there.

Till 

Am Montag 11 Januar 2010 schrieb Ivan Frade:
 Hi,
 
 El vie, 08-01-2010 a las 20:45 +0100, ext Till Harbaum / Lists escribió:
  Hi,
  
  Am Freitag 08 Januar 2010 schrieb Ivan Frade:
 
   see it when i arrive there). This will be supported in tracker 0.7
   (ready to play with on desktop), but not in 0.6/fremantle.
  Using tracker 0.6 limited to images is a start. Do you have example
  code somewhere? I have never worked with tracker before.
 
 We have some (basic) documentation here:
 http://live.gnome.org/Tracker/Documentation/RDF-Query
 
 Tracker is a daemon visible in DBus. In python, connect to the daemon
 directly (an example in my own pet-project [1]). In C, use
 libtracker-client (some examples in MAFW's tracker backend).
 
 There should be some libtracker-client gtk-doc documentation, but it
 looks like library.gnome.org only contains the last unstable version
 (0.7). This is useless for you, the API in 0.7 is _completely_ different
 from 0.6 API. Don't get confused with that.
 
 The properties you can use in your queries are defined here:
 http://git.gnome.org/browse/tracker/tree/data/services?h=tracker-0.6
 
 You can also monitor dbus while using the image-viewer to see some
 queries flying.
 
 Regards,
 
 Ivan
 
 [1]
 https://garage.maemo.org/plugins/ggit/browse.php/?p=mussorgsky;a=blob;f=src/tracker_backend.py;h=e956f38668066423fa9538a1cb69a4082f776fa8;hb=9d71d07b572bdf50114484b28a0e188d742fcdfc
 
 
 

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-11 Thread Ivan Frade
Hi,

El vie, 08-01-2010 a las 20:45 +0100, ext Till Harbaum / Lists escribió:
 Hi,
 
 Am Freitag 08 Januar 2010 schrieb Ivan Frade:

  see it when i arrive there). This will be supported in tracker 0.7
  (ready to play with on desktop), but not in 0.6/fremantle.
 Using tracker 0.6 limited to images is a start. Do you have example
 code somewhere? I have never worked with tracker before.

We have some (basic) documentation here:
http://live.gnome.org/Tracker/Documentation/RDF-Query

Tracker is a daemon visible in DBus. In python, connect to the daemon
directly (an example in my own pet-project [1]). In C, use
libtracker-client (some examples in MAFW's tracker backend).

There should be some libtracker-client gtk-doc documentation, but it
looks like library.gnome.org only contains the last unstable version
(0.7). This is useless for you, the API in 0.7 is _completely_ different
from 0.6 API. Don't get confused with that.

The properties you can use in your queries are defined here:
http://git.gnome.org/browse/tracker/tree/data/services?h=tracker-0.6

You can also monitor dbus while using the image-viewer to see some
queries flying.

Regards,

Ivan

[1]
https://garage.maemo.org/plugins/ggit/browse.php/?p=mussorgsky;a=blob;f=src/tracker_backend.py;h=e956f38668066423fa9538a1cb69a4082f776fa8;hb=9d71d07b572bdf50114484b28a0e188d742fcdfc


___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Michael Cronenworth

Till Harbaum / Lists on 01/07/2010 10:15 AM wrote:

- We'll have to scan all files in every geotag aware app
If you want to create some sort of standard database for holding GPS 
metadata for any file type then you have to write it.



- This consumes much CPU power

Reading a file is hardly CPU intensive.


- This takes a very, VERY long time

Not on an SSD unless you have billions of files.


- This does not work with MP3/WAV/PNG/GIF/AVI/...
Quite right. Why do you expect GPS information to be available for these 
files? Who told you to expect GPS data from those file types?



- This information can hardly be shared between different apps
The standard for JPEG type files is to use EXIF for any and all 
metadata. Any app should and can support reading EXIF.



- My app has to cache/store this information for all media files to
   not be forced to re-scan everything everytime it's being started


I think you need to re-think what your goal is.
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Till Harbaum / Lists
Hi,

thank for you for your reply.

Am Donnerstag 07 Januar 2010 schrieb Michael Cronenworth:
  - This consumes much CPU power
 Reading a file is hardly CPU intensive.
Reading thousands of files is. I really don't have much media stored
on my n900, but it's already 400 mp3 files, 150 jpegs and 40 avi videos.
Scanning them for tags aready would take a long time and even worse
would consume lots of CPU (and thus battery) power.

  - This takes a very, VERY long time
 Not on an SSD unless you have billions of files.
Reading several thousand media files does not take long? You'll have to scan 
all oif them, even if only a fraction of them actually contains geotags as you 
don't know which the ones with geotags are before you actually search for them.

  - This does not work with MP3/WAV/PNG/GIF/AVI/...
 Quite right. Why do you expect GPS information to be available for these 
 files? Who told you to expect GPS data from those file types?
Why should i assume that i can savely ignore them if they all may actually 
contain geotags? Why should i be sure that e.g. maemo-recorder nor any other 
app puts geotags into the wav files it stores? 

  - This information can hardly be shared between different apps
 The standard for JPEG type files is to use EXIF for any and all 
 metadata. Any app should and can support reading EXIF.
But then every single app has to scan every single file. That's awful.

 I think you need to re-think what your goal is.
That's sad as it really limits the usage of geotags. The right solution would 
sure be to let tracker handle this as it's the purpose of tracker to index the 
disk for media files and to provide meta information to all apps interested in 
this.

  Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Till Harbaum / Lists
Hi,

Am Donnerstag 07 Januar 2010 schrieb Michael Cronenworth:
  How do i access geotags?
 With libexif. GPS coordinates are in the EXIF data.
This only works for jpeg images which are only a fraction of media
files stored on an n900.

I was fearing to get some answer like this. This has so many disadvantages:

- We'll have to scan all files in every geotag aware app
- This consumes much CPU power
- This takes a very, VERY long time
- This does not work with MP3/WAV/PNG/GIF/AVI/...
- This information can hardly be shared between different apps
- My app has to cache/store this information for all media files to
  not be forced to re-scan everything everytime it's being started

I am afraid this will mean that such a project doesn't make much sense.

Thanks,
  Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Kimmo Hämäläinen
On Thu, 2010-01-07 at 20:50 +0100, ext Till Harbaum / Lists wrote:
 Hi,

  I think you need to re-think what your goal is. That's sad as it
  really limits the usage of geotags. The right solution would sure be
  to let tracker handle this as it's the purpose of tracker to index the
  disk for media files and to provide meta information to all apps
  interested in this.

Yes, tracker should do it. Fortunately, tracker can be extended to index
all kind of information. CC'ing Ivan Mr. Tracker Frade here...

-Kimmo

 
   Till
 ___
 maemo-developers mailing list
 maemo-developers@maemo.org
 https://lists.maemo.org/mailman/listinfo/maemo-developers

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Cornelius Hald

Michael Cronenworth wrote:

Till Harbaum on 01/07/2010 06:30 AM wrote:

How do i access geotags?



With libexif. GPS coordinates are in the EXIF data.


I didn´t really look into this, but at least for image files tracker 
seems to be prepared to handle geo tags. Not sure if this functionality 
is available in reality, but have a look at the file

/usr/share/tracker/services/image.metadata

There are two properties that look interesting: Image:Location and 
Image:Sublocation


Anyways, it´s just a guess.
Conny
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Michael Cronenworth

Cornelius Hald on 01/08/2010 05:02 AM wrote:

Anyways, it´s just a guess.


That's for images only. Till wants it for *all* file types.
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Michael Cronenworth

Kimmo Hämäläinen on 01/08/2010 04:58 AM wrote:

Yes, tracker should do it. Fortunately, tracker can be extended to index
all kind of information. CC'ing Ivan Mr. Tracker Frade here...


GPS data is stored in tracker for images only. Till wants GPS data for 
*all* file types.

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Till Harbaum / Lists
Hi,

Am Freitag 08 Januar 2010 schrieb Michael Cronenworth:
 GPS data is stored in tracker for images only. Till wants GPS data for 
 *all* file types.
If the tracker really already has basic geotagging support, then i
think it's the only acceptable solution to use it, even if this is currently
limited to images only.

This sounds like a classic chicken/egg problem and as long as only the
image viewer supports geotagging, noone will bother to extend the 
tracker for other formats.

So if tracker can provide geotagging info i'd be more than willing to use
that. Perhaps e.g. the maemo-recorder guys can be convinced to tag
their files and this might in turn cause someone to extend the tracker
functionality to support geotags in sound files ...

I really REALLY think tracker is the only useful way to deal with geotags
especially in a mobile device where indexing may really be expensive 
with respect to CPU power and  battery.

What's the tracker guru's opinion?

Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Ivan Frade
Hi,

El vie, 08-01-2010 a las 15:35 +0100, ext Michael Cronenworth escribió:
 Cornelius Hald on 01/08/2010 05:02 AM wrote:
  Anyways, it´s just a guess.
 
 That's for images only. Till wants it for *all* file types.

 In Fremantle, tracker 0.6 can store the location of Images (basically
the geotags the user set in the image viewer). Those properties contain
text, so you need to use the location API to turn them into coordinates
for your map application.

 About other media types... there is no other format containing
location, so tracker cannot fill that information by itself.

 Our idea for the future is that _applications_ can set location values
for the files (e.g. a shopping-list note in the supermarket, so i can
see it when i arrive there). This will be supported in tracker 0.7
(ready to play with on desktop), but not in 0.6/fremantle.

 Some remarks to the previous comments in the thread:

1) EXIF is not the only format for metadata in images. There is XMP or
IPTC, and you need a hierarchy to choose between them, and handle broken
files and ... well, don't underestimate the problem

2) The idea of scanning and monitoring the filesystem means basically to
duplicate the functionality of tracker (and probably the code ;))

3) Scanning and reading files is not CPU expensive, but needs a lot of
IO, and IO is a very precious resource.

 Regards,

Ivan

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Ivan Frade
Hi,

 I was answering the previous email :) Few more comments.

El vie, 08-01-2010 a las 16:43 +0100, ext Till Harbaum / Lists escribió:
 Hi,
 
 Am Freitag 08 Januar 2010 schrieb Michael Cronenworth:
  GPS data is stored in tracker for images only. Till wants GPS data for 
  *all* file types.

 I really REALLY think tracker is the only useful way to deal with geotags
 especially in a mobile device where indexing may really be expensive 
 with respect to CPU power and  battery.

 We have two problems:
1) Who set the location information? Responsibility of applications.
2) Where should that information be stored? In tracker. 

 but ...
1) No application is really setting location information except the
image viewer (and only for images)
2) Tracker 0.6 cannot store efficiently that information. We could try
to add a File:Location property, so you could set location for
everything known by tracker, but it is going to be very very
inefficient. This will be fixed in 0.7 .

 Regards,

Ivan


___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


RE: How to access geotag information?

2010-01-08 Thread Simon Pickering
   GPS data is stored in tracker for images only. Till wants GPS data 
   for
   *all* file types.
 
  I really REALLY think tracker is the only useful way to deal with 
  geotags especially in a mobile device where indexing may really be 
  expensive with respect to CPU power and  battery.
 
  We have two problems:
 1) Who set the location information? Responsibility of applications.
 2) Where should that information be stored? In tracker. 
 
  but ...
 1) No application is really setting location information 
 except the image viewer (and only for images)
 2) Tracker 0.6 cannot store efficiently that information. We 
 could try to add a File:Location property, so you could set 
 location for everything known by tracker, but it is going to 
 be very very inefficient. This will be fixed in 0.7 .

It would be preferable to also store the lat/lon information so that
applications could use that if they see fit (e.g. map apps) as well as the
pre-reverse geocoded location name, otherwise there's additional overhead
and severe inaccuracy of the geocoding.

From a quick websearch I can see that video can and is geocoded at least
(either once uploaded, or for e.g. some Sony camcorder with a built-in GPS),
so adding support for geocoded videos would be nice.

I can also envision other files adding geocoding metadata about themselves
to the tracker database, even if the file itself doesn't support internal
geocoding metadata (is that possible, I guess it should be?) so adding a
geotag field (or fields I hope for name and lat/lon) would be a nice, cool
and future proof thing to do (but yeah it will waste some space for files
that don't use it, but probably not much, though I've not looked at the db
so I don't know for sure).

Anyway I think it's a shame we don't make more use of our geo-information
and the ability to enable it in general on the N900 - the IM app doesn't
report actual location data which is a real shame (and hence my interest in
using Google's Latitude instead), contacts can contain addresses but not
more accurate lat/lon, etc.

Cheers,


Simon


___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Javier Fernandez Garcia-Boente
On Fri, 2010-01-08 at 18:19 +0200, Ivan Frade wrote:
 Hi,
 

  but ...
 1) No application is really setting location information except the
 image viewer (and only for images)

As far as i know, Camera is also setting location information. The GPS
coordinates are stored in EXIF and the reverse geocoding strings are in
XMP. The location metadata is set for both, images and videos.

-- 
Javier Fernández García-Boente
http://blogs.igalia.com/jfernandez/
www.igalia.com


signature.asc
Description: This is a digitally signed message part
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


RE: How to access geotag information?

2010-01-08 Thread Aldon Hynes
My gut feeling is that as we move forward, geotag type information really
belongs with the file information.  e.g.  I would love to have the ability
to stat a file to find out the geolocation where a file was created as well
as the time that the file was created.  Of course, that is a very big change
right down at the OS level, so until file systems change to include
something like geolocation of creation, Till's approach sounds pretty
interesting.

Aldon
41.3324, -72.9882



-Original Message-
From: maemo-developers-boun...@maemo.org
[mailto:maemo-developers-boun...@maemo.org]on Behalf Of Till Harbaum /
Lists
Sent: Friday, January 08, 2010 10:43 AM
To: Michael Cronenworth
Cc: maemo-developers@maemo.org
Subject: Re: How to access geotag information?


Hi,

Am Freitag 08 Januar 2010 schrieb Michael Cronenworth:
 GPS data is stored in tracker for images only. Till wants GPS data for
 *all* file types.
If the tracker really already has basic geotagging support, then i
think it's the only acceptable solution to use it, even if this is currently
limited to images only.

This sounds like a classic chicken/egg problem and as long as only the
image viewer supports geotagging, noone will bother to extend the
tracker for other formats.

So if tracker can provide geotagging info i'd be more than willing to use
that. Perhaps e.g. the maemo-recorder guys can be convinced to tag
their files and this might in turn cause someone to extend the tracker
functionality to support geotags in sound files ...

I really REALLY think tracker is the only useful way to deal with geotags
especially in a mobile device where indexing may really be expensive
with respect to CPU power and  battery.

What's the tracker guru's opinion?

Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-08 Thread Till Harbaum / Lists
Hi,

Am Freitag 08 Januar 2010 schrieb Ivan Frade:
  About other media types... there is no other format containing
 location, so tracker cannot fill that information by itself.
In this web site you can download wav files which claim to be geotagged:

http://www.freesound.org/samplesViewSingle.php?id=73423

That's why i thought the maemo-recorder could do the same.

 see it when i arrive there). This will be supported in tracker 0.7
 (ready to play with on desktop), but not in 0.6/fremantle.
Using tracker 0.6 limited to images is a start. Do you have example
code somewhere? I have never worked with tracker before.

 3) Scanning and reading files is not CPU expensive, but needs a lot of
 IO, and IO is a very precious resource.
Whatever the limit is: You don't want to do this in every single app.

Reards,
  Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


How to access geotag information?

2010-01-07 Thread Till Harbaum
Hi,

i am planning to add a feature to Maep so that it displays small thumbnails of 
geotagged media data. How do i access geotags? I suppose the correct way to 
access any media files is to go via tracker. Are there any examples to request 
geoinformation from tracker? A little googling reveals many pages saying that 
tracker doesn't index geotags. Is this true? What is the correct way to get 
geotags of all media stored on the device? It sure doesn't make much sense to 
ask tracker for a list of all media and than try to extract geotags from them. 
This would take forever on a big media collection.

Regards,
  Till
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: How to access geotag information?

2010-01-07 Thread Michael Cronenworth

Till Harbaum on 01/07/2010 06:30 AM wrote:

How do i access geotags?



With libexif. GPS coordinates are in the EXIF data.
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers