/// <summary> /// /// </summary> /// <param name="x"></param> /// <param name="insertEvent"></param> /// <param name="sweepInt"></param> public SweepLineEvent(double x, SweepLineEvent insertEvent, SweepLineInterval sweepInt) { xValue = x; this.insertEvent = insertEvent; if (insertEvent != null) eventType = SweepLineEvents.Delete; else eventType = SweepLineEvents.Insert; this.sweepInt = sweepInt; }
/// <summary> /// /// </summary> private void BuildIndex() { sweepLine = new SweepLineIndex(); foreach (var ring in rings) { var env = ring.EnvelopeInternal; var sweepInt = new SweepLineInterval(env.MinX, env.MaxX, ring); sweepLine.Add(sweepInt); } }
/// <summary> /// /// </summary> private void BuildIndex() { sweepLine = new SweepLineIndex(); for (int i = 0; i < rings.Count; i++) { ILinearRing ring = (ILinearRing)rings[i]; Envelope env = (Envelope)ring.EnvelopeInternal; SweepLineInterval sweepInt = new SweepLineInterval(env.MinX, env.MaxX, ring); sweepLine.Add(sweepInt); } }
/// <summary> /// /// </summary> private void BuildIndex() { _sweepLine = new SweepLineIndex(); for (int i = 0; i < _rings.Count; i++) { LinearRing ring = (LinearRing)_rings[i]; IEnvelope env = ring.EnvelopeInternal; SweepLineInterval sweepInt = new SweepLineInterval(env.Minimum.X, env.Maximum.X, ring); _sweepLine.Add(sweepInt); } }
public void Overlap(SweepLineInterval s0, SweepLineInterval s1) { LinearRing innerRing = (LinearRing) s0.Item; LinearRing searchRing = (LinearRing) s1.Item; if (innerRing == searchRing) return; if (_nestedClass.IsInside(innerRing, searchRing)) _isNonNested = false; //throw new NotImplementedException(); }
/// <summary> /// /// </summary> /// <param name="s0"></param> /// <param name="s1"></param> public void Overlap(SweepLineInterval s0, SweepLineInterval s1) { ILinearRing innerRing = (ILinearRing)s0.Item; ILinearRing searchRing = (ILinearRing)s1.Item; if (innerRing == searchRing) { return; } if (container.IsInside(innerRing, searchRing)) { isNonNested = false; } }
private void BuildIndex() { sweepLine = new SweepLineIndex(); int nCount = rings.Count; for (int i = 0; i < nCount; i++) { LinearRing ring = (LinearRing)rings[i]; Envelope env = ring.Bounds; SweepLineInterval sweepInt = new SweepLineInterval(env.MinX, env.MaxX, ring); sweepLine.Add(sweepInt); } }
public virtual void Overlap(SweepLineInterval s0, SweepLineInterval s1) { LinearRing innerRing = (LinearRing)s0.Item; LinearRing searchRing = (LinearRing)s1.Item; if (innerRing == searchRing) { return; } if (m_objRingTester.IsInside(innerRing, searchRing)) { isNonNested = false; } }
public void Overlap(SweepLineInterval s0, SweepLineInterval s1) { LinearRing innerRing = (LinearRing)s0.Item; LinearRing searchRing = (LinearRing)s1.Item; if (innerRing == searchRing) { return; } if (_nestedClass.IsInside(innerRing, searchRing)) { _isNonNested = false; } //throw new NotImplementedException(); }
private void BuildIndex() { _sweepLine = new SweepLineIndex(); for (int i = 0; i < _rings.Count; i++) { LinearRing ring = (LinearRing) _rings[i]; Envelope env = ring.GetEnvelopeInternal(); SweepLineInterval sweepInt = new SweepLineInterval(env.MinX, env.MaxX, ring); _sweepLine.Add(sweepInt); } }
/// <summary> /// /// </summary> /// <param name="start"></param> /// <param name="end"></param> /// <param name="s0"></param> /// <param name="action"></param> private void ProcessOverlaps(int start, int end, SweepLineInterval s0, ISweepLineOverlapAction action) { /* * Since we might need to test for self-intersections, * include current insert event object in list of event objects to test. * Last index can be skipped, because it must be a Delete event. */ for (int i = start; i < end; i++) { SweepLineEvent ev = (SweepLineEvent)events[i]; if (ev.IsInsert) { SweepLineInterval s1 = ev.Interval; action.Overlap(s0, s1); nOverlaps++; } } }
/// <summary> /// /// </summary> /// <param name="sweepInt"></param> public virtual void Add(SweepLineInterval sweepInt) { SweepLineEvent insertEvent = new SweepLineEvent(sweepInt.Min, null, sweepInt); events.Add(insertEvent); events.Add(new SweepLineEvent(sweepInt.Max, insertEvent, sweepInt)); }
/// <summary> /// /// </summary> /// <param name="s0"></param> /// <param name="s1"></param> public virtual void Overlap(SweepLineInterval s0, SweepLineInterval s1) { LinearRing innerRing = (LinearRing) s0.Item; LinearRing searchRing = (LinearRing) s1.Item; if (innerRing == searchRing) return; if (_container.IsInside(innerRing, searchRing)) _isNonNested = false; }