OpenLayers OpenLayers

Ticket #1100 (new feature)

Opened 11 months ago

Last modified 2 months ago

Add ability to navigate in the time dimension for layers

Reported by: Marten.Sward Assigned to:
Priority: minor Milestone: 3.0 Release
Component: Control Version: 2.5
Keywords: control time navigation Cc: marten.sward@smhi.se, bitner@dbspatial.com, rvb@qps.nl
State: Needs Discussion

Description

This class adds functionality to navigate in the time dimension (useful for some WMS-layers)

See http://www.atavus.se/TimeNavigation/timenavigation.html for a live example.

The user specifies a "time-group" in the layer properties.

 var temprature_wms =  new OpenLayers.Layer.WMS.Untiled( "Temprature",
                "http://openmetoc.met.no/metoc/metocwms",
                {layers: "ECMWF-IFS_2:TMP",                         
                 transparent: "true", format: "image/png" },
                 {timegroup: 'ECMWF'});

This time-group should be the same for all layers that is to be controlled by the navigation control.

Following code adds the time navigation control:

map.addControl( new OpenLayers.Control.TimeNavigation( 
            	"" ,
            	{timegroup: 'ECMWF', 
                timearray: ["2007-10-23T00:00:00" , "2007-10-23T06:00:00" , "2007-10-23T12:00:00" , "2007-10-23T18:00:00"],
            					timeformat_callback_func: 'dateconv'}));

timegroup, this is the name of the timegroup which the array with times should apply to.

timeformat_callback_func, this is optional. It's used to give the user a way to format the dates that are displayed on the map.

Attachments

TimeNavigation.js (4.0 kB) - added by Marten.Sward on 10/22/07 03:52:43.
Class for adding a timenavigation control
AnimatedTimeNavigation.rar (18.8 kB) - added by openlayers on 04/16/08 08:42:10.
Marten.Sward's original code automated (start/stop/rewind)

Change History

10/22/07 03:52:43 changed by Marten.Sward

  • attachment TimeNavigation.js added.

Class for adding a timenavigation control

10/22/07 07:30:55 changed by bitner

  • cc changed from marten.sward@smhi.se to marten.sward@smhi.se, bitner@dbspatial.com.

04/15/08 06:29:32 changed by openlayers

  • cc changed from marten.sward@smhi.se, bitner@dbspatial.com to marten.sward@smhi.se, bitner@dbspatial.com, rvb@qps.nl.
  • state changed.

i think this is a really interesting feature to have

04/15/08 06:35:19 changed by openlayers

  • state set to Needs Discussion.
  • milestone set to Future.

04/16/08 08:42:10 changed by openlayers

  • attachment AnimatedTimeNavigation.rar added.

Marten.Sward's original code automated (start/stop/rewind)

04/16/08 08:43:03 changed by openlayers

AnimatedTimeNavigation.rar works with 2.6

07/18/08 07:56:19 changed by openlayers

  • milestone changed from Future to 3.0 Release.