freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

[計算機軟件及應用]introductiontoopenlayersworkshopfoss4g(編輯修改稿)

2025-09-13 04:20 本頁面
 

【文章內(nèi)容簡介】 arguments.var imagery = new ( Global Imagery, , {layers: bluemarble})。The first argument, Global Imagery, is a string name for the layer. This is only used by ponents that display layer names (like a layer switcher) and can be anything of your choosing.The second argument, , is the string URL for a Web Map Service.The third argument, {layers: bluemarble} is an object literal with properties that bee parameters in our WMS request. In this case, we’re requesting images rendered from a single layer identified by the name bluemarble.Tasks1. This same WMS offers a layer named openstreetmap. Change the value of the layers param from bluemarble to openstreetmap.2. In addition to the layers parameter, a request for WMS imagery allows for you to specify the image format. The default for this layer is image/jpeg. Try adding a second property in the params object named format. Set the value to another image type (. image/png).Your revised Constructor should look like:var imagery = new ( Global Imagery, , {layers: openstreetmap, format: image/png})。3. Save your changes and reload the map: @workshop_url@/A map displaying the openstreetmap layer as image/png.Having worked with dynamically rendered data from a Web Map Service, let’s move on to learn about cached tile services.. Cached TilesBy default, the WMS layer makes requests for 256 x 256 (pixel) images to fill your map viewport and beyond. As you pan and zoom around your map, more requests for images go out to fill the areas you haven’t yet visited. While your browser will cache some requested images, a lot of processing work is typically required for the server to dynamically render images.Since tiled layers (such as the WMS layer) make requests for images on a regular grid, it is possible for the server to cache these image requests and return the cached result next time you (or someone else) visits the same area resulting in better performance all around.. The Web Map Service specification allows a lot of flexibility in terms of what a client can request. Without constraints, this makes caching difficult or impossible in practice.At the opposite extreme, a service might offer tiles only at a fixed set of zoom levels and only for a regular grid. These can be generalized as XYZ layers you can consider X and Y to indicate the column and row of the grid and Z to represent the zoom level.. The OpenStreetMap (OSM) project is an effort to collect and make freely available map data for the world. OSM provides a few different renderings of their data as cached tile sets. These renderings conform to the basic XYZ grid arrangement and can be used in an OpenLayers map. The constructor accesses OpenStreetMap tiles.Tasks1. Open the file from the previous section in a text editor and change the map initialization code to look like the following:2. script3. var geographic = new (EPSG:4326)。4. var mercator = new (EPSG:900913)。5.6. var world = new (180, 89, 180, 89).transform(7. geographic, mercator8. )。9. var center = new (, ).transform(10. geographic, mercator11. )。12.13. var options = {14. projection: mercator,15. units: m,16. maxExtent: world17. }。18. var map = new (mapid, options)。19.20. var osm = new ()。21. (osm)。22.23. (center, 9)。24. /script25. In the head of the same document, add a few style declarations for the layer attribution.26. style27. mapid {28. width: 512px。29. height: 256px。30. }31. .olControlAttribution {32. fontsize: 10px。33. bottom: 5px。34. right: 5px。35. }36. /style37. Save your changes, and refresh the page in your browser: @workshop_url@/A map with an OpenStreetMap layer.. A Closer Look. ProjectionsReview the first 2 lines of the initialization script:var geographic = new (EPSG:4326)。var mercator = new (EPSG:900913)。Geospatial data can e in any number of coordinate reference systems. One data set might use geographic coordinates (longitude and latitude) in degrees, and another might have coordinates in a local projection with units in meters. A full discussion of coordinate reference systems is beyond the scope of this module, but it is important to understand the basic concept.OpenLayers needs to know the coordinate system for your data. We represent this with an object. You create a new projection object by using a string that represents the coordinate reference system (EPSG:4326 and EPSG:900913 above).. Locations Transformedvar world = new (180, 89, 180, 89).transform( geographic, mercator)。var center = new (, ).transform( geographic, mercator)。The OpenStreetMap tiles that we will be using are in a Mercator projection. Because of this, we need to set things like the maximum extent and initial center using Mercator coordinates. Since it is relatively easy to find out the coordinates for a place of interest in geographic coordinates, we use the transform method to turn geographic coordinates into Mercator coordinates.NoteYou may notice that the world bounds created above do not really cover the entire world. For now, you’ll have to accept that this particular transform doesn’t behave well at the poles so we adjust the bounds to pensate.. Custom Map Optionsvar options = { projection: mercator, units: m, maxExtent: world}。var map = new (mapid, options)。In the previous example we used the default options for our map. In this example, we set some custom map options. First, we set the map projection property to the Mercator projection we created above. Next we set the map units to m for meters, and finally we set the maxExtent to the world (again in Mercator coordinates).. Layer Creation and Map
點擊復制文檔內(nèi)容
外語相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖片鄂ICP備17016276號-1