/[thuban]/trunk/thuban/Thuban/Model/layer.py
ViewVC logotype

Diff of /trunk/thuban/Thuban/Model/layer.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1587 by bh, Fri Aug 15 10:31:07 2003 UTC revision 1599 by bh, Mon Aug 18 12:45:28 2003 UTC
# Line 8  Line 8 
8    
9  __version__ = "$Revision$"  __version__ = "$Revision$"
10    
11    import os
12  import warnings  import warnings
13    
14  from Thuban import _  from Thuban import _
# Line 254  class Layer(BaseLayer): Line 255  class Layer(BaseLayer):
255          return self.store.Shape(index)          return self.store.Shape(index)
256    
257      def ShapesInRegion(self, bbox):      def ShapesInRegion(self, bbox):
258          """Return the ids of the shapes that overlap the box.          """Return an iterable over the shapes that overlap the bounding box.
259    
260          Box is a tuple (left, bottom, right, top) in unprojected coordinates.          The bbox parameter should be the bounding box as a tuple in the
261            form (minx, miny, maxx, maxy) in unprojected coordinates.
262          """          """
263          if self.projection is not None:          if self.projection is not None:
264              left, bottom, right, top = bbox              left, bottom, right, top = bbox
# Line 369  class RasterLayer(BaseLayer): Line 371  class RasterLayer(BaseLayer):
371          BaseLayer.__init__(self, title, visible = visible)          BaseLayer.__init__(self, title, visible = visible)
372    
373          self.projection = projection          self.projection = projection
374          self.filename = filename          self.filename = os.path.abspath(filename)
375    
376          self.bbox = -1          self.bbox = -1
377    

Legend:
Removed from v.1587  
changed lines
  Added in v.1599

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26