[Geomoose-users] slideshow/tour within GeoMoose

Brent Fraser bfraser at geoanalytic.com
Tue Jun 15 14:47:39 EDT 2010


All,

   The prototype using meta/refresh works ok.  It automatically "fowards" to the 
next set of instructions after a set number of seconds, and doesn't hang the 
browser.

   While it's not AJAX-y, it does avoid pinning the CPU.  I'm moving on to add 
more functionality: pause, play, and some kind of html template (header, footer) 
mechanism for easier configuring.

The basic architecture:

In the mapbook (right now I'm using the layer's metadata button , but that will 
have to change):

slideshow.php?slideshow=myShow1&slide=mySlide0&mode=pause

when clicked a window opens with a "play" button invoking:

slideshow.php?slideshow=myShow1&slide=mySlide1&mode=play

a "pause" button would invoke:

slideshow.php?slideshow=myShow1&slide=mySlide1&mode=pause


The slideshow.php would look at the "mode" to decide to insert a refresh:

   if mode=play, then insert a refresh (the browser will wait 10 seconds):
     <meta http-equiv="Refresh" content="10; 
URL=slideshow=myShow1&slide=mySlide1&mode=play">
     (and insert a pause button)
   else
     no meta tag, but insert a play button


The meat would be in the slide1, 2, etc html files (currently coded by hand), 
something like:

  <script type='text/javascript'>
   function runslide()
   {
     if (window.opener && !window.opener.closed)
     {
		var mapWin = window.opener;
		var GeoMOOSE = mapWin.GeoMOOSE;		
		GeoMOOSE.clearPopups();
		GeoMOOSE.zoomToExtent(-12711115, 6271185,-12665227, 6309521);
		GeoMOOSE.turnLayerOn("Quickbird/Waterton");
		GeoMOOSE.addPopup(-12687075, 6290155, 200, 100, "This is a popup.");		
     }
   }
</script>

   </head>

   <body onload="runslide();">

wrapped in a header and footer.

Bob,  If you use the GeoMOOSE changeLayerURL in the slide files, you have the 
server automatically deliver different images for your weather animations. The 
GPS via SVG/GML workflow might take some additions to GeoMOOSE....


Best Regards,
Brent Fraser



Brent Fraser wrote:
>    I had considered using Flash or creating screen movies using CamStudio (and 
> we will do that for our "Help" page).  But I think what we're looking for is the 
> ability to have a timed tour, but give the user the ability to interrupt the 
> tour and pan/zoom/view layers, then resume the tour.
> 
>    I think I'll look into the HTML self-update technique using the meta tag:
> 
> <meta http-equiv="Refresh" content="60; 
> URL=http://www.mymap.com/slideshow/php?slide=1">
> 
> and the "slide=" gets incremented in the PHP.  Dunno how to do the 
> interupt/resume yet.
> 
> 
> Once we've got a technique that works, it could likely be enhanced to
> 	- send links to images (for weather animation), and
> 	- send XML/GML for GPS positions
> 	
> Your History recorder is a good idea too...
> 
> Brent
> 
> Bob Basques wrote:
>>
>> Brent,
>>
>>
>> Jim K. has been looking at how to animate some things for GPS trails and 
>> such, I think he has some ideas here.  A generic approach would be 
>> beneficial for a number of functions.
>>
>>
>> Some functionality we're look looking at (or have looked at):
>>
>>
>> ** Animating through multiple (temporal) images (for Weather animations 
>> for example).
>>
>>
>> ** Animation of a GPS track, could be images and/or SVG (or some other 
>> canvas type thing)
>>
>>
>> ** There was a conversation at one point about adding in some sort of 
>> scripting support to GeoMoose that was interpreted on the client.  HTML 
>> can update itself for example.
>>
>>
>> ** There was also talk of adding in a History recorder that could allow 
>> for replaying a user session.
>>
>>
>> To date I just use a Flash desktop movie maker for these types of 
>> things, It's pretty quick to do too.  There are free ones and pay for, 
>>  I like Flashback myself.
>>
>>
>> Here are a few that I've done recently:
>>
>>
>> _/http://www.mngeo.state.mn.us/committee/emprep/structures/index.html/_
>>
>> (look for "Video Tutorials")
>>
>>
>> bobb
>>
>>
>>
>>
>>
>>>>> Brent Fraser <bfraser at geoanalytic.com> wrote:
>> All,
>>
>>    If you followed last week's "Layer Functions" thread you know that I 
>> used the
>> GeoMOOSE API to create a "Zoom To Layer Extents" button on the metadata 
>> results
>> page.
>>
>>    Our marketing guy asked if it would be possible to create a 
>> "slide-show" or
>> "tour" using similar techniques.  At first I thought it would be easy 
>> and had
>> the php return:
>>
>> var mapWin = window.opener;
>> var GeoMOOSE = mapWin.GeoMOOSE;
>>
>> GeoMOOSE.clearPopups();
>> GeoMOOSE.zoomToExtent(-12711115, 6271185,-12665227, 6309521);
>> GeoMOOSE.turnLayerOn("Quickbird/Waterton");
>> GeoMOOSE.addPopup(-12687075, 6290155, 200, 100, "Quickbird Imagery 
>> supplied by
>> Geoanalytic");
>>
>> wait(3000);
>>
>> GeoMOOSE.clearPopups();
>> GeoMOOSE.zoomToExtent(-12702314, 6719493,-12696849, 6724881);
>> GeoMOOSE.turnLayerOn("Parcels/all");
>> GeoMOOSE.addPopup(-12701359, 6721881, 200, 100, "Parcels supplied by 
>> AltaLIS");
>>
>>
>> only to find out that Javascript has no wait/sleep/pause function, and 
>> in fact
>> the whole idea is contrary to the async nature of JavaScript.  I did 
>> find some
>> info at http://www.devcheater.com/ outlining the problem, some solutions and
>> their effect on various browsers.  The best approach looks like using 
>> XMLHttp
>> and server-side scripting to get things to wait, but perhaps there's a 
>> better way?
>>
>> Any thoughts?
>>
>> Brent Fraser
>>
>>
>> ------------------------------------------------------------------------------
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> _______________________________________________
>> Geomoose-users mailing list
>> Geomoose-users at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/geomoose-users
>>
> 
> 
> ------------------------------------------------------------------------------
> ThinkGeek and WIRED's GeekDad team up for the Ultimate 
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
> lucky parental unit.  See the prize list and enter to win: 
> http://p.sf.net/sfu/thinkgeek-promo
> _______________________________________________
> Geomoose-users mailing list
> Geomoose-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geomoose-users
> 





More information about the Geomoose-users mailing list