{"id":106,"date":"2007-12-29T23:13:01","date_gmt":"2007-12-30T06:13:01","guid":{"rendered":"http:\/\/www.bigroom.org\/wordpress\/?p=106"},"modified":"2007-12-29T23:13:01","modified_gmt":"2007-12-30T06:13:01","slug":"proposed-formats-for-geotagging-arbitrary-types-of-media","status":"publish","type":"post","link":"http:\/\/www.bigroom.org\/wordpress\/?p=106","title":{"rendered":"Proposed format(s) for geotagging arbitrary types of media"},"content":{"rendered":"<p>Yet more thoughts on geotagging &#8211; here&#8217;s what I&#8217;ve come up with so far.<\/p>\n<p>The format needs to handle only two fundamental data types &#8211; points and polygons.  It also obviously needs to handle &#8220;lines&#8221; or tracks, but those are made of &#8220;points&#8221;.  Polygon, for my purposes, might be unnecessary and I&#8217;m not sure if I should leave it in.  I&#8217;m reluctant to leave it out &#8211; that way you could easily georeference media to a building or field&#8217;s outline, for example.  On the other hand, I&#8217;m trying to keep this format terse and concise &#8211; I&#8217;m not trying to merely embed .gpx or .kml files in things.<\/p>\n<p>A &#8220;point&#8221;, as I am thinking of defining it here, is made of up to seven attributes (more or less in order of importance): a <span class=\"moreinfo\" title=\"Or should this be 'Longitude\/Latitude' instead?  There seems to be some controversy about this.\" onclick=\"alert(this.title);\">latitude\/longitude<\/span> pair, elevation, timestamp, track-ID, heading, and angle.  A polygon is the same, except that it contains a list of at least <span class=\"moreinfo\" title=\"GeoRSS says four, with the demand that the last lat\/lon pair be identical to the first.  This seems redundant to me - if it's a polygon, the segment connecting the last position with the first ought to be implicit.\" onclick=\"alert(this.title);\">three<\/span> lat\/lon\/optional-elevation sets.  It still only has a single timestamp, though, just like a &#8220;point&#8221;.  I suppose in some odd cases one could even define a track as a series of polygons &#8211; defining the field of view in a video taken from the bottom of an airplane that&#8217;s taking off, for example.<\/p>\n<p>Leaving aside the question of polygons for now, I&#8217;m envisioning two possible formats which I will arbitrarily name &#8220;geotag&#8221; (XML-type) and &#8220;geostring&#8221;(simple text) for the moment.<\/p>\n<p>I picture a geotag entry looking something like this:<\/p>\n<p><tt>&lt;geotag:point lat=\"41.228063\" lon=\"-115.058119\" elev=\"1720.901m\" datetime=\"20071115T143000-06\" trackid=\"1\" heading=\"340\" angle=\"-5.0\"&gt;Metropolis Hotel&lt;\/geotag:point&gt;<\/tt><\/p>\n<p>In this format, the optional description of the point is between the opening and closing tags there.  &#8220;lat&#8221; and &#8220;lon&#8221; might be better as a single &#8220;latlon&#8221; or &#8220;coord&#8221; attribute, with the latitude and longitude separated by commas (i.e. <tt>&lt;geotag:point coord=\"41.228063,-115.058119\"&gt;:&lt;\/geotag:point&gt;<\/tt>)<\/p>\n<p>A &#8220;geotring&#8221; point might look something like this instead:<\/p>\n<p><tt>geostring:point:41.228063:-115.058119:1720.901m:20071115T143000-06:1:340:-5.0:geostring<\/tt><\/p>\n<p>Not sure if the closing &#8220;geostring&#8221; is really necessary here, but it would make backwards-compatibility easier if fields were added to future revisions.  As with the geotag, it might be better to treat the lat\/lon pair (the only mandatory information for a minimal &#8220;point&#8221; definition) as a single field, so the minimal &#8220;geotag&#8221; example above done as a &#8220;geostring&#8221; would look something like: <tt>geostring:41.228063,-115.058119::::::geostring<\/tt><\/p>\n<p>Even as I write this, I find myself leaning towards combining the latitude and longitude into a single field, if for no other reason than it means each point only has one required field.  Either way, I currently think the fields ought to be defined thus:<\/p>\n<ul>\n<li>latitude and longitude are <span class=\"moreinfo\" title=\"We are not friggin' ancient Babylonians, we don't need that stinking 'minutes' and 'seconds' crap.\" onclick=\"alert(this.title);\">decimal degrees<\/span>.  Either may be prefixed by a + or &#8211; (lat: +=&#8221;Northern Hemisphere&#8221;, -=&#8221;Southern Hemisphere&#8221;, Lon: +=East, -=West) &#8211; if neither is there, + will be assumed.  Latitude and longitude are required for every point.<\/li>\n<li>Elevation may be suffixed by &#8220;m&#8221; or &#8220;f&#8221; (for &#8220;meters&#8221; or &#8220;feet&#8221;).  If neither is specified, meters are assumed.<\/li>\n<li>Timestamp is in the <a href=\"http:\/\/en.wikipedia.org\/wiki\/ISO_8601\">ISO 8601<\/a> &#8220;basic format&#8221;.  If neither &#8220;Z&#8221; or an offset from UTC are specified, &#8220;the viewer&#8217;s local time&#8221; should be assumed (which is kind of silly, but it still would allow one to synchronize a track with, say, an audio recording or video.)<\/li>\n<li>trackid is any arbitrary alphanumeric term with a maximum of, say, 16 characters (is that enough?)  Any points with the same trackid are assumed to be part of the same track.  If unspecified, the point is assumed to be unrelated to any other points (if any exist) that may be in the same file.<\/li>\n<li>Heading is in decimal degrees from 0 to 360.  This represents facing a particular (horizontal) direction from the point in question. &#8220;Which direction the camera was pointing&#8221; in the case of a photograph.<\/li>\n<li>Angle is in decimal degrees from -90 to 90.  This represents an angle above or below the current elevation at that point (for a picture, this would represent the upward or downward angle that the camera was pointing when the picture was taken.)<\/li>\n<\/ul>\n<p>Hmmm, if I shorten &#8220;geostring&#8221; to &#8220;geostr&#8221; and either eliminate the &#8220;data type&#8221; field (&#8220;point&#8221;) or just reduce it to a single letter, that entire and complete &#8220;geostring&#8221; example would fit even into a single tiny 64-character comment field, if there are any file formats still floating around limited to that kind of small metadata size.<\/p>\n<p>My main goal here is to make it easy to create files tagged with this information.  So long as it&#8217;s easily read and not likely to get separated from the file it describes, using the data for anything ought to be easy, even if one has to do it &#8220;by hand&#8221;.  As was <a href=\"http:\/\/cholmes.wordpress.com\/2007\/12\/01\/producing-not-consuming-makes-the-geoweb-go-round\/\" title=\"Producing, not consuming, makes the GeoWeb go\">mentioned on the &#8220;Into the Pudding&#8221; blog<\/a> (found via the <a href=\"http:\/\/georss.org\/blog\/\" title=\"GeoRSS Weblog\">GeoRSS blog<\/a>), having applications that can read metadata is useless if nobody&#8217;s putting the metadata in their files to begin with.  If an acceptable format can be worked out, I intend to start making as much georeferenced information available as possible.<\/p>\n<p>Who&#8217;s with me?  Comments, suggestions, offers of patronage, anyone?<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Yet more thoughts on geotagging &#8211; here&#8217;s what I&#8217;ve come up with so far. The format needs to handle only two fundamental data types &#8211; points and polygons. It also obviously needs to handle &#8220;lines&#8221; or tracks, but those are made of &#8220;points&#8221;. Polygon, for my purposes, might be unnecessary and I&#8217;m not sure if &hellip; <a href=\"http:\/\/www.bigroom.org\/wordpress\/?p=106\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Proposed format(s) for geotagging arbitrary types of media<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[25,4,13,12,15,40,5,21,33,2],"tags":[],"class_list":["post-106","post","type-post","status-publish","format-standard","hentry","category-computer-nerdity","category-feedback-solicitation","category-me-me-me","category-meta-blogging","category-methods","category-neogeography","category-nerdity","category-play-with-it","category-the-big-room","category-where-was-i"],"_links":{"self":[{"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/106","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=106"}],"version-history":[{"count":0,"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/106\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=106"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=106"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.bigroom.org\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=106"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}