5. La géomatique en quelques mots
Discipline ayant pour objet la gestion des données
géographiques en faisant appel aux sciences et
technologies reliées à
● l'acquisition
● le stockage
● le traitement
● et la diffusion
... de données géographiques. (réf: OQLF)
6. La géomatique en 1000 mots
Acquisition
Diffusion
Stockage
Traitement
et analyse
7. Google Maps
● Depuis 2005
● La cartographie disponible pour tous
● Néogéographe vs Paléogéographe
8.
9.
10. Les logiciels libres en géomatique
● freegis.org
● 356 entrées
● OSGeo
● 14 projets logiciels
● + 7 en cours d'incubation
14. MapServer
●Permet de construire ses propres cartes avec ses propres
données géospatiales.
●MapServer lit des données géoréférencées et retourne des
images standards dans le format désiré.
● Implémente les normes OGC :
●WMS
●WFS
●SLD
●GML
●KML
24. Données?
Shapefile :
● roads.shp
● roads.shx
● roads.dbf
Fichiers statiques
Attributs stockés dans un fichier DBF
L'extension dbase de PHP est encore utile!!!
26. PostGIS
Base de données relationelle
Ajout de nouveaux types “spatiaux”
Opérateurs et fonctions géographiques
- interrogation
- édition
- analyse
Aussi puissant qu'un SIG
27. PostGIS
● Extension spatiale pour PostgreSQL
● Stockage, requête et manipulation d'objets spatiaux
directement dans la base de données
● Suit la spécification OGC Simple Features for SQL
● Base de données relationnelle...
28. Jonction de 2 tables
Table avec géométrie Table avec géométrie et attributs
30. Jonction de 2 tables
SELECT * FROM roads
LEFT JOIN roads_attr
ON roads.gid = roads_attr.gid;
31. PostGIS et MapServer
LAYER
CONNECTIONTYPE POSTGIS
CONNECTION "host=yourhost dbname=db user=you password=pass port=pgport"
DATA "the_geom FROM roads"
....
32. PostGIS et MapServer
LAYER
CONNECTIONTYPE POSTGIS
CONNECTION "host=yourhost dbname=db user=you password=pass port=pgport"
DATA "the_geom FROM (
SELECT *
FROM roads
LEFT JOIN roads_attr
ON roads.gid=roads_attr.gid
) as jointable”
.....
36. SELECT
distance(hospitals.the_geom,roads.the_geom)
FROM hospitals, roads;
37. SELECT
road.gid,
road.street,
min(distance(hospitals.the_geom,r.the_geom)) as
min_distance
FROM roads,hospitals
GROUP BY road.gid, street;
38. CLASS
EXPRESSION ([dist] < 1000)
COLOR 0 255 0
END
CLASS
EXPRESSION ([dist] >= 1000 AND [dist] < 2000)
COLOR 255 255 0
END
CLASS
EXPRESSION ([dist] >= 2000 AND [dist] < 4000)
COLOR 192 192 0
END
CLASS
EXPRESSION ([dist] >= 4000)
COLOR 255 0 0
END
39. PostGIS
Il y a beaucoup de fonctions comme distance()
http://postgis.refractions.net/docs/reference.html
40. OpenLayers
http://openlayers.org/
● Cartographie dynamique
● API complet
● Librairie JavaScript
● Aucune dépendance à
un logiciel serveur
● Licence de type BSD
● Offre les
fonctionnalités
de base de navigation
41. À la base: JS
function init(){
map = new OpenLayers.Map('map');
layer = new OpenLayers.Layer.WMS(
"OpenLayers WMS",
"http://vmap0.tiles.osgeo.org/wms/vmap0",
{layers: 'basic'}
);
map.addLayer(layer);
}
43. Sources de données
var map = new OpenLayers.Map({
div: "map",
● GYMO layers: [ point title description icon
new OpenLayers.Layer.WMS( orange title
10,20 my my orange description
● KML 2,4 my aqua title
"WMS", "http://vmap0.tiles.osgeo.org/wms/vmap0", my aqua description
42,-71
{layers: "basic"} my purple title description<br/>is great
● Fichier texte ), 47.543,-78.222 title description
46.789,-77.123
new OpenLayers.Layer.Vector("KML", { title2 description2
● WMS strategies: [new OpenLayers.Strategy.Fixed()],
protocol: new OpenLayers.Protocol.HTTP({
url: "kml/lines.kml",
format: new OpenLayers.Format.KML({
extractStyles: true,
extractAttributes: true,
maxDepAth: 2
})
})
})
],
center: new OpenLayers.LonLat(-112.169, 36.099),
zoom: 11
});
56. Exemples OpenLayers
Accessible OpenLayers Document Drag GML Parser
All Overlays with Google and OSM Double Set Center Google with Overlay
OpenLayers Overlays Only Drag Feature Google (v3) allOverlays Layer
map.panTo OpenLayers Draw Feature Google (v3) Layer
ArcGIS Server 9.3 Rest API Dynamic POIs via a Text Layer Google Layer
ArcIMS Thematic Editing Toolbar Named Graphics
ArcIMS Event Handling Graticule
Attribution OpenLayers Gutter
Base Layers Filter Strategy OpenLayers Select and Highlight Feature
Vector Behavior (Fixed/HTTP/GML) Filter Encoding Hover Handler
Bing Fractional Zoom Image Layer
Boxes Full Screen OpenLayers Geometry Intersection
Showing Browser Name GeoJSON KaMap
Buffer GeoRSS from Flickr in OpenLayers KML Layer
Canvas Renderer GeoRSS Marker Parsing gx:Track in KML
Click Handler GeoRSS KML Parser
Click Event WFS GetFeature (GeoServer) Late Rendering
Map Controls Feature Info Layer Opacity
Custom Control Feature Info in Popup Layer Load Monitoring
Custom Style Feature Info Layer Switcher
Debug GML Layer Basic Single WMS
57. Paging Strategy
Rule Based Style
StyleMap
Feature Styles
Rotation Style
Exemples OpenLayers
MapGuide Layer Advanced OSM Layer Snapping
Unique Value Styles
OSM + Google Maps + KML Reprojection
KML Layer
Map "Teleportation" and Rendering
MapServer Layer Basic OSM SOS client
TileCache
MapServer Single Tile Mode Overview Map OpenLayers Spherical Mercator
Tiled Map Service
Resize a Marker Pan and Zoom Panels OpenLayers Split Feature
Vector Feature Transformation Box
Markers Layer Custom Control.Panel BBOX Strategy
Transition
Using a Layer.Text to display markers GeoRSS PointTrack in OpenLayers Cluster Strategy Threshold
WorldWind
OpenLayers Measure Popup Matrix Cluster Strategy
XYZ Layer with Offset
MultiMap Popup Mayhem Paging Strategy
Virtual Earth
OpenLayers Modify Feature Layer Projections Rule Based Style
OpenLayers Labeled features
MousePosition Control Gears Protocol StyleMap
Drawing Simple Vector Features
OpenLayers Mousewheel Interval OpenLayers Regular Polygon Feature Styles
Vector Formats
MultiMap Mercator Resize Features Programatically Rotation Style
OpenLayers Spherical Mercator
Multiple Server URLS OpenLayers Restricted Extent Unique Value Styles
WFS Protocol and Filter
Navigation Control Rotate vector features OSM + Google Maps + KML Reprojection
WFS Transaction
Map Navigation History Open Popup on Layer.Vector KML Layer
Vector Behavior
A navToolbar with an alwaysZoom ZoomBox OpenLayers Select Feature OpenLayers
WFS Reprojection
Navigation Toolbar: Outside the Map Setting a Visual Extent Map "Teleportation" and Rendering
Snap/Split and Persist via WFS
NavToolbar Demo SLD Parser TileCache
WFS United States (GeoServer)
Untiled Styled Layer Descriptor (SLD) Tiled Map Service
WMC
Z-Index/Y-Order SLD based selection on WMS layers Vector Feature Transformation Box
WMS Untiled
OSM and Google Togethe Snapping & Splitting Transition
WMS version 1.3 (axis order)
WorldWind layers Snapping WorldWind
WMS
Wrapping the Date Line SOS client Virtual Earth
WMSDescribeLayer Parser
XHTML OpenLayers Spherical Mercator Virtual Earth
Basic WMS via HTTP-POST protocol with a large SLD included
XML Format OpenLayers Split Feature OpenLayers Labeled features
WMS Time
Basic ESRI Map Cache BBOX Strategy Drawing Simple Vector Features
Web Map Tile Service (WMTS) Capabilities Parsing
Yahoo Base Layer Cluster Strategy Threshold Vector Formats
WMTS GetFeatureInfo Control
Zoomify Layer Cluster Strategy OpenLayers Spherical Mercator
Web Map Tile Service (WMTS) Layer
Zoom Level
60. Concept
● Absence de la composante géospatiale dans ExtJS
● Absence des concepts pour les applications riches dans
OpenLayers
● Présence de la carte dans un panel ExtJS
● Encapsulement des objets d'OpenLayers dans des
composantes data d'ExtJS
66. Modifying Popups
Exemples GeoExt Interactive Print Extent
Print Your Map
Attribute Form Print Preview Window
Attribute Store & Reader Feature Renderer
Grid with Features Filter Form Panel
Layer Tree Toolbar with Actions
Layer Opacity Slider Tree Nodes
Legend Panel Tree Legend
Map Panel Vector Legend
Map Panel (in a Viewport) WMS Capabilities Store
Map Panel (in a Window) WMS Capabilities Tree
Permalink Scale Chooser
Feature Popup Zoom Slider