1 / 35

A more efficient map overlay method for Terralib

Universidade Federal de Viçosa. Departamento de Informática. A more efficient map overlay method for Terralib. Vinícius Lopes Rodrigues Marcus Vinícius Alvim Andrade Gilberto Ribeiro de Queiroz Mirella Antunes de Magalhães. Introduction. TerraLib: A Component Library for GIS Development

leann
Download Presentation

A more efficient map overlay method for Terralib

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Universidade Federal de Viçosa Departamento de Informática A more efficient map overlay method for Terralib Vinícius Lopes Rodrigues Marcus Vinícius Alvim Andrade Gilberto Ribeiro de Queiroz Mirella Antunes de Magalhães

  2. Introduction TerraLib: A Component Library for GIS Development Developed by: INPE, Tecgraf/PUC-Rio, FUNCATE Implementation of “Small GIS”

  3. Terralib • Terralib has a geometric algorithms module • Used for manipulation of spatial data • Contains all basic operations involving simple geometric forms (Points, Lines, Polygons) • Spatial data are manipulated in a lower level

  4. Terralib • Terralib has also a functional module • This module uses basic geometric operations to build functions in a higher level

  5. Map Overlay Description: Is used to combine the information of two maps Calculates the geometrical overlay between map polygons and joins the non-spatial information of two maps

  6. Map Overlay • Example:

  7. Terralib’s Polygon Overlay • Basic operation for map overlay • Computes intersection, union or difference of two polygons • Named TeOverlay – included in kernel of Terralib • Based on Margalit and Knott’s algorithm

  8. Terralib’s Polygon Overlay

  9. Terralib’s Polygon Overlay • The computation of the intersection points on the boundaries is essential to obtain the final result • These points are used to determine the fragmentation of the boundary • The generated fragments are grouped according to chosen operation

  10. Terralib’s Map Overlay • Let M1 and M2 be two maps • Suppose that M1has less polygons than M2

  11. b2 M1: blue M2: red a3 a2 a1 b1

  12. Terralib’s Map Overlay • In Terralib, the original method proceeds as the following: • for each polygon bi in M1, a spatial query on the database is done, fetching all the polygons on the map M2 which bounding box intercepts the bi’s bounding box

  13. b2 a3 a2 a1 b1

  14. Terralib’s Map Overlay • The operation TeOverlay is applied to determine the intersection between the polygon ai and all polygons returned by the query. • To execute the operation above, it is necessary to determine the intersection points between the borders of the polygons.

  15. b2 a3 a2 a1 b1

  16. Terralib’s Map Overlay • All the regions returned by the TeOverlay operation are stored in the resulting map • Each computed polygon has attributes from both the original polygons (maps)

  17. Terralib’s Map Overlay Considerations • This operation proceeds many spatial queries on the database that implies a large execution time • The same polygon of the map M2 could be processed twice or more times

  18. An alternative map overlay • Developed to avoid the database queries • The intersection points are found based on the Bentley & Ottman’s plane sweep algorithm.

  19. An alternative map overlay • The maps are full loaded from the database to build two segments sets. • So, the intersection algorithm is used to determine the intersection points between the segments of these two sets.

  20. b2 a3 a2 a1 b1

  21. An alternative map overlay • After finding the intersection points, a matrix is built to store them. • In this matrix, the position ( i , j ) contains the intersection points between polygon bi from M1 and aj from M2

  22. a1 a2 a3 b2 b1 b2 p5 p6 p1 p5 p3 p7 p2 p6 p4 p7 p8 p8 a3 a2 a1 p3 p4 p2 p1 b1

  23. An alternative map overlay • In this version, TeOverlay was modified to receive as parameter the intersection points previously calculated • For each position of the matrix where the list is not empty, the new version of TeOverlay is called with the respective polygons and their intersection points

  24. An alternative map overlay • Special case: • if a polygon a1is “inside” another polygon b1. • In this case, the list of intersection points is empty but the polygons intersection is not. • To circumvent this case, the algorithm checks if the polygons bounding box intersect each other. • If they intersect, only a point-polygon localization is needed

  25. Results • Input Maps:

  26. Results M3 M1 M4 M5

  27. Results M1 x M3 M1 x M2 M1 x M4 M5 x M6

  28. Results • Time Results

  29. Future Work • Implement a plane sweep based map overlay • Based on Kriegel’s algorithm • Does not require database queries and intersection points are determined as result regions are generated

  30. Questions ? ? ? ? ? ? ??? ? ??? ? ? ? ? ? ? Vinícius Lopes vlopes@dpi.ufv.br

More Related