Exemple #1
0
        /// <summary>
        /// Checks whether this window overlaps a position
        /// </summary>
        /// <param name="p">The position to examine</param>
        /// <returns>True if the position overlaps this window (may be exactly
        /// coincident with the perimeter)</returns>
        internal bool IsOverlap(IPointGeometry p)
        {
            ulong val = SpatialIndex.ToUnsigned(p.Easting.Microns);

            if (val < m_X.Min || val > m_X.Max)
            {
                return(false);
            }

            val = SpatialIndex.ToUnsigned(p.Northing.Microns);
            return(val >= m_Y.Min && val <= m_Y.Max);
        }
Exemple #2
0
 /// <summary>
 /// Creates a new <c>Range</c>, converting the supplied values into unsigned space.
 /// </summary>
 /// <param name="d">The positional dimension the range refers to</param>
 /// <param name="a">One end of the range (either the min or the max)</param>
 /// <param name="b">The other end of the range (either the min or the max)</param>
 internal RangeValue(Dimension d, long a, long b)
     : this(d, SpatialIndex.ToUnsigned(a), SpatialIndex.ToUnsigned(b))
 {
 }