Esempio n. 1
0
        public IGeographicMbr Intersection(IGeographicMbr other)
        {
            if (!LatitudeRange.Intersects(other.LatitudeRange))
            {
                return(null);
            }

            var longitude = LongitudeRange.Intersection(other.LongitudeRange);

            if (longitude == null)
            {
                return(null);
            }

            var latitude = new Range(
                Math.Max(LatitudeRange.Low, other.LatitudeRange.Low),
                Math.Min(LatitudeRange.High, other.LatitudeRange.High));

            return(new IntersectionResult {
                LatitudeRange = latitude,
                LongitudeRange = longitude
            });
        }
Esempio n. 2
0
 public bool Intersects(EpsgArea other)
 {
     return(LongitudeRange.Intersects(other.LongitudeRange) &&
            LatitudeRange.Intersects(other.LatitudeRange));
 }
Esempio n. 3
0
 public bool Intersects(IGeographicMbr other)
 {
     return(LongitudeRange.Intersects(other.LongitudeRange) &&
            LatitudeRange.Intersects(other.LatitudeRange));
 }