[OpenLayers-Users] Performance?

Erik Uzureau euzuro at gmail.com
Tue Aug 15 20:59:15 CDT 2006


Hi Jeff,

Are you running on 1.0 version or on the svn HEAD?

We just put a bunch of new funky gridding stuff into the trunk, like
reusing divs, adjustable tile-buffer, and spiral gridding.

To modify the off-current-view tiles, try fiddling with the 'buffer'
property in Grid.js -- ex:

        function init(){
            map = new OpenLayers.Map( $('map') );
            layer = new OpenLayers.Layer.WMS( "OpenLayers WMS",
                    "http://labs.metacarta.com/wms/vmap0", {layers:
'basic'},
                    { tileSize: new OpenLayers.Size(800,475),
                      buffer: 1 });
            map.addLayer(layer);

            map.setCenter(new OpenLayers.LonLat(lon, lat), zoom);
            map.addControl( new OpenLayers.Control.LayerSwitcher() );
        }


The default is set to 2 but you can take it down to 1 (as above) and that
will probably
speed things up for you, though UI-wise it might be less sweet.

Note that setting the buffer to 0 will not work.


So yeah, the reason you are seeing so many tiles loaded is because it is
loading a buffer
of two tiles around the viewport. Also, the reason you dont see simple
numbers like 9
and 25 is because of the way we have implemented gridding -- with cacheing
in mind, OL
uses a sort of world-grid at each zoom level, which means that specifying a
tile size of the
same size as the viewport won't necessarily (in fact quite unlikely) mean
that it will load one
tile smack-dab in the center of the viewport. Does that make sense?

--Erik



On 8/15/06, Jeff Dege <jdege at korterra.com> wrote:
>
> What seems odd to me is the number of tiles being loaded.
>
> I have a div of 800x600, and for testing I've set the tile size to
> 800x600.
>
> With only one layer, I'd expect to see at most nine tiles downloaded.  But
> the browser's status bar says there are 30 pictures being downloaded.
>
> Is there a way of controlling how many off-current-view tiles are
> downloaded?
>
> > -----Original Message-----
> > From: users-bounces at openlayers.org
> > [mailto:users-bounces at openlayers.org] On Behalf Of Gary Townsend
> > Sent: Tuesday, August 15, 2006 9:57 AM
> > To: users at openlayers.org
> > Subject: Re: [OpenLayers-Users] Performance?
> >
> > The only performance issues I've found so far have been with how each
> > browser handles the imagery returned. Using untiled images I find that
> > firefox loads the interlaced images somewhat faster than IE.
> >
> > -----Original Message-----
> > From: users-bounces at openlayers.org
> > [mailto: users-bounces at openlayers.org] On
> > Behalf Of Jeff Dege
> > Sent: August 15, 2006 7:20 AM
> > To: users at openlayers.org
> > Subject: Re: [OpenLayers-Users] Performance?
> >
> > I've been running through WMS.
> >
> > > -----Original Message-----
> > > From: Marcos Cobeña [mailto: marcoscobena at gmail.com]
> > > Sent: Tuesday, August 15, 2006 5:29 AM
> > > To: Jeff Dege
> > > Cc: users at openlayers.org
> > > Subject: Re: [OpenLayers-Users] Performance?
> > >
> > > Hi Jeff,
> > >
> > > Just one question, are you calling MS through WMS queries or just
> > > using MS layer recently coded?
> > >
> > > If you are using WMS, it seems better to contact MS guys, they'll
> > > surely be able to explain why it takes more time than expected.
> > >
> > > Hope this helps.
> > >
> > > Regards,
> > >
> > > 2006/8/14, Jeff Dege < jdege at korterra.com>:
> > > > Is there some fundamental reason why accessing MapServer
> > > maps through
> > > > OpenLayers is so much slower than doing so using either
> > > MapServer's CGI
> > > > or scripting interfaces?
> > > >
> > > > I'm experimenting with a moderate data set - seven shape
> > > files, largest
> > > > is 150MB.  When I ask MapServer's CGI executable to draw me
> > > a map, it
> > > > takes a couple of seconds.  The MapScript DLL is even
> > > faster, despite
> > > > being asked to do more.
> > > >
> > > > But OpenLayers can take forever - upwards of sixty seconds,
> > > sometimes,
> > > > to draw a map of the same size.
> > > >
> > > > I've tried Ka-Map (directly, I've not been able to get the
> > > Ka-Map layer
> > > > within OpenLayers to work), and while it redraws cached
> > > tiles quickly,
> > > > it's only moderately faster than OpenLayers at drawing them
> > > in the first
> > > > place.
> > > >
> > > > Is this normal?
> > > >
> > > > What can I do to fix it?
> > > >
> > > >
> > > > _______________________________________________
> > > > Users mailing list
> > > > Users at openlayers.org
> > > > http://mailman-viper.python-hosting.com/listinfo/users
> > > >
> > >
> > >
> > > --
> > > Marcos - http://www.youcannoteatbits.org
> > >
> >
> > _______________________________________________
> > Users mailing list
> > Users at openlayers.org
> > http://mailman-viper.python-hosting.com/listinfo/users
> >
> >
> > _______________________________________________
> > Users mailing list
> > Users at openlayers.org
> > http://mailman-viper.python-hosting.com/listinfo/users
> >
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://mailman-viper.python-hosting.com/listinfo/users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman-viper.python-hosting.com/pipermail/users/attachments/20060815/506b4675/attachment-0001.html


More information about the Users mailing list