hi, a super simple version of this has been useful to me. just via calling<br>
kaMap.getGeoExtents, then pad that (so it adds ~1/2 length of the viewport on each side) and fetch<br>
all of the markers in that expanded extent. then register for an event of EXTENTS_CHANGED and check<br>
if the new getGeoExtents results fall with the expanded extents. if so, do nothing. otherwise, fetch new markers. <br>
<br>
base, most of the slowness will come from having 500+ images attached
to your div. but you can assign an AJAX (call()) to each div to fetch
the meat of the information instead of sending it with the inital
marker import. if you have the div id correspond to database id, that
keeps it simple. <br>
-brent<br>
<br><div><span class="gmail_quote">On 2/28/06, <b class="gmail_sendername">Stephen Woodbridge</b> &lt;<a href="mailto:woodbri@swoodbridge.com">woodbri@swoodbridge.com</a>&gt; wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Paul Spencer wrote:<br>&gt; Ok, then the event could be triggered as a result of the call to<br>&gt; checkWrap and if any wrapping has occurred you would get an event<br>&gt; indicating the new extents of the meta viewport.&nbsp;&nbsp;You could then make
<br>&gt; your overlay image the size of the meta viewport (in pixels) and pin&nbsp;&nbsp;it<br>&gt; to the top/left image in the meta viewport.&nbsp;&nbsp;When this event is<br>&gt; triggered, you would reposition the image and change its source so it
<br>&gt; would load a new overlay from the server.<br>&gt;<br>&gt; Are you going to implement this and contribute?<br><br>Matt has been working on this, but I think he is currently pinning an<br>image just the size of the viewport so we have to request a new one for
<br>every pan. I think the plan is to contribute some of the stuff he has<br>been working on, but I don't know any of the details.<br><br>-Steve<br><br>&gt; Cheers<br>&gt;<br>&gt; Paul<br>&gt;<br>&gt; On 28-Feb-06, at 9:23 AM, Stephen Woodbridge wrote:
<br>&gt;<br>&gt;&gt; Hi Paul,<br>&gt;&gt;<br>&gt;&gt; These get called for every tile load request if I understand your<br>&gt;&gt; description, if I pan diagonally then I would expect to get rows<br>&gt;&gt; +cols-1 (or more) events triggered as you add new rows and columns&nbsp;&nbsp;to
<br>&gt;&gt; the meta_viewport.<br>&gt;&gt;<br>&gt;&gt; I think this a little too granular, but we might be able to roll up<br>&gt;&gt; these events. What I was thinking about was to consider the<br>&gt;&gt; additional tiles around the viewport as a meta_viewport that has
<br>&gt;&gt; extents. Then when the viewport moves outside the meta_viewport a<br>&gt;&gt; single event is triggered and the new extents of the meta_viewport<br>&gt;&gt; are made available.<br>&gt;&gt;<br>&gt;&gt; If it is easy to get this from what you suggested below then that
<br>&gt;&gt; would be great other you might consider add this type of event as I<br>&gt;&gt; think anyone trying to track an overlay with a server side image&nbsp;&nbsp;will<br>&gt;&gt; be able to use this.<br>&gt;&gt;<br>&gt;&gt; -Steve
<br>&gt;&gt;<br>&gt;&gt; Paul Spencer wrote:<br>&gt;&gt;<br>&gt;&gt;&gt; Steve,<br>&gt;&gt;&gt; I think that we should expose two events:<br>&gt;&gt;&gt; KAMAP_TILE_CHANGING<br>&gt;&gt;&gt; KAMAP_TILE_CHANGED<br>&gt;&gt;&gt; this would potentially allow the interface to expose the number&nbsp;&nbsp;of
<br>&gt;&gt;&gt; tiles that are 'in the queue' and could be used for other&nbsp;&nbsp;purposes<br>&gt;&gt;&gt; to, like fixing overlays etc<br>&gt;&gt;&gt; KAMAP_TILE_CHANGING would be triggered in the setTile method of<br>&gt;&gt;&gt; _layer (and affliates).
<br>&gt;&gt;&gt; KAMAP_TILE_CHANGED would be triggered in the kaMap_imgOnLoad function<br>&gt;&gt;&gt; One thing to consider is that images do fail to load for various<br>&gt;&gt;&gt; reasons and we need to be aware of the difference between an&nbsp;&nbsp;image
<br>&gt;&gt;&gt; that is loaded the first time and an image that is loaded&nbsp;&nbsp;because<br>&gt;&gt;&gt; of&nbsp;&nbsp;an error, otherwise tile counts could be seriously&nbsp;&nbsp;impacted.<br>&gt;&gt;&gt; Would this meet your needs?<br>&gt;&gt;&gt; Cheers
<br>&gt;&gt;&gt; Paul<br>&gt;&gt;&gt; On 28-Feb-06, at 7:58 AM, Stephen Woodbridge wrote:<br>&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; This is an excellent question as we have been doing something<br>&gt;&gt;&gt;&gt; similar with router overlays. We currently overlay an image just
<br>&gt;&gt;&gt;&gt; the size of the viewport, but it would make sense to ask for a<br>&gt;&gt;&gt;&gt; larger image say the size of the preloaded tile extents and then<br>&gt;&gt;&gt;&gt; only update that when additional tiles are requested because the
<br>&gt;&gt;&gt;&gt; preloaded tile extent needs to change because of panning or<br>&gt;&gt;&gt;&gt; zooming. Could this be made an ka-map event that can be easily&nbsp;&nbsp;hooked?<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; -Steve<br>
&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; Base Bloc wrote:<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt; Dear all,<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp;First off I would like to say that ka-map 0.2 is a fantastic<br>&gt;&gt;&gt;&gt;&gt; piece of kit and thanks for all the work that people have put&nbsp;&nbsp;in
<br>&gt;&gt;&gt;&gt;&gt; to this.<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp;I am currently building an application using 0.2 and I am&nbsp;&nbsp;using<br>&gt;&gt;&gt;&gt;&gt; the addObjectGeo function to add markers along with&nbsp;&nbsp;mouseover<br>&gt;&gt;&gt;&gt;&gt; events (pop-up windows) to the map. All is working as&nbsp;&nbsp;it should
<br>&gt;&gt;&gt;&gt;&gt; and is looking good. My concern now is the number of&nbsp;&nbsp;markers; the<br>&gt;&gt;&gt;&gt;&gt; application is covering most of Southeast Asia and&nbsp;&nbsp;the number of<br>&gt;&gt;&gt;&gt;&gt; markers is going to be high. I am looking to use&nbsp;&nbsp;Ajax to connect
<br>&gt;&gt;&gt;&gt;&gt; to a MySQL database to retrieve the point data&nbsp;&nbsp;relevant to the<br>&gt;&gt;&gt;&gt;&gt; area of the map being viewed, as if all of the&nbsp;&nbsp;points were to be<br>&gt;&gt;&gt;&gt;&gt; retrieved in one go it would result in a&nbsp;&nbsp;serious performance hit
<br>&gt;&gt;&gt;&gt;&gt; for the user.<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp;I'm no ka-map expert, but I was wondering how ka-map does this<br>&gt;&gt;&gt;&gt;&gt; efficiently with the tiles; as in it gets x number of tiles<br>&gt;&gt;&gt;&gt;&gt; closest to the area being viewed then moves outwards, is there
<br>&gt;&gt;&gt;&gt;&gt; anyway to use the variable(s) that are being sent to the server<br>&gt;&gt;&gt;&gt;&gt; to&nbsp;&nbsp;request the tiles to also query the database and return the<br>&gt;&gt;&gt;&gt;&gt; point&nbsp;&nbsp;data in an equally efficient manor?
<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp;Thanks in advance for your thoughts.<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp;Chris<br>&gt;&gt;&gt;&gt;&gt;&nbsp;&nbsp; ~~~~~~~~~~~~~~~~~~~~~~~~~~~<br>&gt;&gt;&gt;&gt;&gt; Christopher Brown<br>&gt;&gt;&gt;&gt;&gt; Head of Internet Development
<br>&gt;&gt;&gt;&gt;&gt; Base Bloc Cambodia<br>&gt;&gt;&gt;&gt;&gt; #33, 123, Phnom Penh, Cambodia.<br>&gt;&gt;&gt;&gt;&gt; P.O. Box 2086<br>&gt;&gt;&gt;&gt;&gt; <a href="http://www.basebloc.com">www.basebloc.com</a><br>&gt;&gt;&gt;&gt;&gt; Tel (+885) 12 315 302
<br>&gt;&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;&gt; -------------------------------------------------------------------<br>&gt;&gt;&gt;&gt;&gt; -- ---<br>&gt;&gt;&gt;&gt;&gt; _______________________________________________<br>
&gt;&gt;&gt;&gt;&gt; ka-Map-users mailing list<br>&gt;&gt;&gt;&gt;&gt; <a href="mailto:ka-Map-users@lists.maptools.org">ka-Map-users@lists.maptools.org</a><br>&gt;&gt;&gt;&gt;&gt; <a href="http://lists.maptools.org/mailman/listinfo/ka-map-users">
http://lists.maptools.org/mailman/listinfo/ka-map-users</a><br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt;<br>&gt;&gt;&gt;&gt; _______________________________________________<br>&gt;&gt;&gt;&gt; ka-Map-users mailing list
<br>&gt;&gt;&gt;&gt; <a href="mailto:ka-Map-users@lists.maptools.org">ka-Map-users@lists.maptools.org</a><br>&gt;&gt;&gt;&gt; <a href="http://lists.maptools.org/mailman/listinfo/ka-map-users">http://lists.maptools.org/mailman/listinfo/ka-map-users
</a><br>&gt;&gt;&gt;<br>&gt;&gt;&gt; +-----------------------------------------------------------------+<br>&gt;&gt;&gt;
|Paul
Spencer&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="mailto:pspencer@dmsolutions.ca">pspencer@dmsolutions.ca</a>&nbsp;&nbsp; |<br>&gt;&gt;&gt; +-----------------------------------------------------------------+<br>&gt;&gt;&gt;
|Applications &amp; Software
Development&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|<br>&gt;&gt;&gt;
|DM Solutions Group
Inc&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://www.dmsolutions.ca/|">http://www.dmsolutions.ca/|</a><br>&gt;&gt;&gt; +-----------------------------------------------------------------+<br>&gt;&gt;<br>&gt;&gt;<br>&gt;<br>&gt; +-----------------------------------------------------------------+
<br>&gt;
|Paul
Spencer&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="mailto:pspencer@dmsolutions.ca">pspencer@dmsolutions.ca</a>&nbsp;&nbsp; |<br>&gt; +-----------------------------------------------------------------+<br>&gt;
|Applications &amp; Software
Development&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;|<br>&gt;
|DM Solutions Group
Inc&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a href="http://www.dmsolutions.ca/|">http://www.dmsolutions.ca/|</a><br>&gt; +-----------------------------------------------------------------+<br>&gt;<br>&gt;<br>&gt;<br>&gt;<br>&gt;<br><br>_______________________________________________
<br>ka-Map-users mailing list<br><a href="mailto:ka-Map-users@lists.maptools.org">ka-Map-users@lists.maptools.org</a><br><a href="http://lists.maptools.org/mailman/listinfo/ka-map-users">http://lists.maptools.org/mailman/listinfo/ka-map-users
</a><br></blockquote></div><br>