示例#1
0
 def __add__(self, other):
     if not isinstance(other, MapExtent):
         raise NotImplemented
     if other.is_default:
         return self
     if self.is_default:
         return other
     return MapExtent(merge_bbox(self.llbbox, other.llbbox), SRS(4326))
示例#2
0
 def __add__(self, other):
     if not isinstance(other, MapExtent):
         raise NotImplemented
     if other.is_default:
         return self
     if self.is_default:
         return other
     return MapExtent(merge_bbox(self.llbbox, other.llbbox), SRS(4326))
示例#3
0
文件: grid.py 项目: imclab/mapproxy
    def _tiles_bbox(self, tiles):
        """
        Returns the bbox of multiple tiles.
        The tiles should be ordered row-wise, bottom-up.

        :param tiles: ordered list of tiles
        :returns: the bbox of all tiles
        """
        ll_bbox = self.tile_bbox(tiles[0])
        ur_bbox = self.tile_bbox(tiles[-1])
        return merge_bbox(ll_bbox, ur_bbox)
示例#4
0
文件: grid.py 项目: tjay/mapproxy
    def _tiles_bbox(self, tiles):
        """
        Returns the bbox of multiple tiles.
        The tiles should be ordered row-wise, bottom-up.

        :param tiles: ordered list of tiles
        :returns: the bbox of all tiles
        """
        ll_bbox = self.tile_bbox(tiles[0])
        ur_bbox = self.tile_bbox(tiles[-1])
        return merge_bbox(ll_bbox, ur_bbox)