<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Several thousands is too much indeed. You could :<br>
<br>
* use the BBOX strategy instead of Fixed to request for features
in the current extent only<br>
* have a WMS layer on zoomed out scales and switch to WFS on
zoomed in scales, but you wouldn't be able to interact with your WMS
as you do with your vector features...<br>
* take a look at the GetFeature control and see if that could do
the trick (currently not working, but look at the code to get the
idea) :<br>
<a class="moz-txt-link-freetext" href="http://dev.openlayers.org/releases/OpenLayers-2.10/examples/getfeature-wfs.html">http://dev.openlayers.org/releases/OpenLayers-2.10/examples/getfeature-wfs.html</a><br>
* setup an OGC filter to your vector layer to get only specific
features (if your data have some kind of attribute you could filter
on), and make only specific features display on specific zoom
levels. I already did something like that, see an example here :
<a class="moz-txt-link-freetext" href="http://bs-dev2.mapgears.com/webmap/">http://bs-dev2.mapgears.com/webmap/</a><br>
<br>
Best regards,<br>
<br>
Alexandre<br>
<br>
<br>
On 11-03-01 01:35 PM, Andrew Stewart wrote:
<blockquote
cite="mid:94816848A8EB3941B1E8592F425827A981E7FF07E3@chex2.crdnet.ca"
type="cite">
<meta content="text/html; charset=UTF-8" http-equiv="Content-Type">
<meta name="GENERATOR" content="MSHTML 8.00.6001.19019">
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="370313418-01032011">Actually I modified
the strategies to be - </span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="370313418-01032011"></span></font> </div>
<div dir="ltr" align="left"><span class="370313418-01032011">
<p><font color="#0000ff" face="Arial" size="2">strategies: [</font></p>
<p><font size="2"><font color="#0000ff" face="Arial">new</font><font
color="#0000ff" face="Arial">
OpenLayers.Strategy.Fixed(),</font></font></p>
<p><font size="2"><font color="#0000ff" face="Arial">new</font><font
color="#0000ff" face="Arial">
OpenLayers.Strategy.Cluster()</font></font></p>
<p><font color="#0000ff" face="Arial" size="2">],</font></p>
<p> </p>
<p><span class="370313418-01032011"><font color="#0000ff"
face="Arial" size="2">Now I am getting the points
showing up but there is still quite a delay in loading /
zooming etc. Is there anyway I can optimize this further
by limiting features etc? </font></span></p>
</span></div>
<div> </div>
<br>
<div dir="ltr" class="OutlookMessageHeader" align="left"
lang="en-us">
<hr tabindex="-1">
<font face="Tahoma" size="2"><b>From:</b>
<a class="moz-txt-link-abbreviated" href="mailto:openlayers-users-bounces@lists.osgeo.org">openlayers-users-bounces@lists.osgeo.org</a>
[<a class="moz-txt-link-freetext" href="mailto:openlayers-users-bounces@lists.osgeo.org">mailto:openlayers-users-bounces@lists.osgeo.org</a>] <b>On
Behalf Of </b>Andrew Stewart<br>
<b>Sent:</b> March 01, 2011 11:31 AM<br>
<b>To:</b> <a class="moz-txt-link-abbreviated" href="mailto:openlayers-users@lists.osgeo.org">openlayers-users@lists.osgeo.org</a><br>
<b>Subject:</b> RE: [OpenLayers-Users] WMSGetFeatureInfo + xy
mouse coordinates, can this be done?<br>
</font><br>
</div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011">So I am having
success with point features below 100.. but is it also
possible to use this with many point features (several
thousand?)</span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011">My code below is
trying to use the cluster strategy.. previously it was Fixed
but that causes my map to freeze when loading the several
thousand points. But when I switch to cluster nothing
happens and no points appear, any advice on what I'm doing
wrong? </span></font></div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011"></span></font> </div>
<div dir="ltr" align="left"><font color="#0000ff" face="Arial"
size="2"><span class="925202918-01032011"><font
color="#0000ff" size="2"><font color="#0000ff" size="2"> //Hydrant<br>
var test_hydrants = new
OpenLayers.Layer.Vector("Hydrant", {<br>
</font></font></span></font></div>
<div dir="ltr" align="left">
<p><font color="#0000ff" face="Arial" size="2"><font
color="#0000ff" size="2"><font color="#0000ff" size="2">
strategies: [new OpenLayers.Strategy.Cluster()],</font></font></font></p>
<p><font color="#0000ff" face="Arial" size="2"><font
color="#0000ff" size="2"><font color="#0000ff" size="2">
protocol: new OpenLayers.Protocol.WFS({<br>
url: wfs,<br>
featureType: "Hydrants",<br>
featureNS: "<a moz-do-not-send="true"
href="http://www.intergraph.com/geomedia/gml">http://www.intergraph.com/geomedia/gml</a>",<br>
featurePrefix: "gmgml",<br>
srsName: "EPSG:3776",<br>
//filter: filter,<br>
geometryName: "Geometry",<br>
version: "1.1.0"<br>
})<br>
});<br>
<br>
</font></font><font color="#0000ff" size="2"><font
color="#0000ff" size="2"> //Add Vector Layers to
Map<br>
map.addLayer(test_hydrants);</font></font></font></p>
</div>
<div> </div>
<div> </div>
<br>
<div dir="ltr" class="OutlookMessageHeader" align="left"
lang="en-us">
<hr tabindex="-1">
<font face="Tahoma" size="2"><b>From:</b>
<a class="moz-txt-link-abbreviated" href="mailto:openlayers-users-bounces@lists.osgeo.org">openlayers-users-bounces@lists.osgeo.org</a>
[<a class="moz-txt-link-freetext" href="mailto:openlayers-users-bounces@lists.osgeo.org">mailto:openlayers-users-bounces@lists.osgeo.org</a>] <b>On
Behalf Of </b>Alexandre Dube<br>
<b>Sent:</b> March 01, 2011 7:52 AM<br>
<b>To:</b> <a class="moz-txt-link-abbreviated" href="mailto:openlayers-users@lists.osgeo.org">openlayers-users@lists.osgeo.org</a><br>
<b>Subject:</b> Re: [OpenLayers-Users] WMSGetFeatureInfo + xy
mouse coordinates, can this be done?<br>
</font><br>
</div>
50~ shouldn't be a problem. IMHO, it would be a good idea to make
the switch to WFS.<br>
<br>
Cheers,<br>
<br>
Alexandre<br>
<br>
On 11-03-01 09:39 AM, Andrew Stewart wrote:
<blockquote
cite="mid:94816848A8EB3941B1E8592F425827A981E7FF07E0@chex2.crdnet.ca"
type="cite">
<pre wrap="">
Ok thanks.. So basically if my web service does not support tolerance (which I'm pretty sure is the case) then there is not much I can do with openlayers to fix this problem.. Besides possibly changing my features into markers from my WFS and giving those markers tooltips/hotspots but not sure what the performance would be on that since I need sometimes 50+ markers.
-----Original Message-----
From: <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:openlayers-users-bounces@lists.osgeo.org">openlayers-users-bounces@lists.osgeo.org</a> [<a moz-do-not-send="true" class="moz-txt-link-freetext" href="mailto:openlayers-users-bounces@lists.osgeo.org">mailto:openlayers-users-bounces@lists.osgeo.org</a>] On Behalf Of Alexandre Dube
Sent: March 01, 2011 6:49 AM
To: <a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:openlayers-users@lists.osgeo.org">openlayers-users@lists.osgeo.org</a>
Subject: Re: [OpenLayers-Users] WMSGetFeatureInfo + xy mouse coordinates, can this be done?
Hi,
That could be setup in your web mapping service. If you use MapServer,
you could set the Layer object definition "TOLERANCE" parameter for that.
Regards,
Alexandre
[1] <a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://mapserver.org/mapfile/layer.html">http://mapserver.org/mapfile/layer.html</a> (search for "TOLERANCE")
On 11-02-28 10:02 PM, Planet)x wrote:
</pre>
<blockquote type="cite">
<pre wrap="">I have a slight problem which has to do with my WMS mainly but wondering if
there is a way to program around it. Well problem is I can increase the
symbol size for points on my Web service but the geometry of the point
(centroid) remains the same. Therefore when using a
OpenLayers.Control.WMSGetFeatureInfo the feature info is never returned
until I move the mouse directly in the middle of the point feature (and also
lines unfortunately). Question is can I somehow force the mouse to be moved
to the center of the point when it nears a symbol.. and is there anyway to
actually get the entire coordinates for the symbol so I can use them to do
the featureinfo somehow? Not sure if this makes sense or if there is another
approach I can utilize to do this.. appreciate any advice!
</pre>
</blockquote>
<pre wrap=""><fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="mailto:Users@lists.osgeo.org">Users@lists.osgeo.org</a>
<a moz-do-not-send="true" class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/openlayers-users">http://lists.osgeo.org/mailman/listinfo/openlayers-users</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
Alexandre Dubé
Mapgears
<a moz-do-not-send="true" class="moz-txt-link-abbreviated" href="http://www.mapgears.com">www.mapgears.com</a>
</pre>
<div>
<p>
</p>
<hr>
[This message has been scanned for security content threats and
viruses.]<br>
<br>
[The City of Red Deer I.T. Services asks that you please
consider the environment before printing this e-mail.]<br>
</div>
<div>
<p>
</p>
<hr>
This e-mail is intended for the original recipient(s) only. If
you have received it in error, please advise the sender and
delete this message. </div>
<div>
<p>
</p>
<hr>
[This message has been scanned for security content threats and
viruses.]<br>
<br>
[The City of Red Deer I.T. Services asks that you please
consider the environment before printing this e-mail.]<br>
</div>
<div>
<hr>
This e-mail is intended for the original recipient(s) only. If
you have received it in error, please advise the sender and
delete this message.
</div>
<pre wrap="">
<fieldset class="mimeAttachmentHeader"></fieldset>
_______________________________________________
Users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Users@lists.osgeo.org">Users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/openlayers-users">http://lists.osgeo.org/mailman/listinfo/openlayers-users</a>
</pre>
</blockquote>
<br>
<br>
<pre class="moz-signature" cols="72">--
Alexandre Dubé
Mapgears
<a class="moz-txt-link-abbreviated" href="http://www.mapgears.com">www.mapgears.com</a>
</pre>
</body>
</html>