0

apparently xmin,zmin,xmax,zmax is more intuitive than xmin,zmin,xmax,zmax for some people

This commit is contained in:
Andrew Brown
2012-02-26 21:08:03 -05:00
parent f43498d033
commit eede25d2e1
3 changed files with 6 additions and 7 deletions

View File

@@ -170,9 +170,9 @@ def validateCrop(value):
if len(value) != 4:
raise ValidationException("The value for the 'crop' setting must be a tuple of length 4")
value = tuple(int(x) for x in value)
if value[0] >= value[1]:
if value[0] >= value[2]:
raise ValidationException("About your crop numbers, the xmax value must be greater than the xmin value")
if value[2] >= value[3]:
if value[1] >= value[3]:
raise ValidationException("About your crop numbers, the zmax value must be greater than the zmin value")
return value

View File

@@ -517,7 +517,7 @@ class RotatedRegionSet(RegionSetWrapper):
yield x,z,mtime
class CroppedRegionSet(RegionSetWrapper):
def __init__(self, rsetobj, xmin, xmax, zmin, zmax):
def __init__(self, rsetobj, xmin, zmin, xmax, zmax):
super(CroppedRegionSet, self).__init__(rsetobj)
self.xmin = xmin//16
self.xmax = xmax//16