Spine.SkeletonBounds.IntersectsSegment C# (CSharp) 메소드

IntersectsSegment() 공개 메소드

Returns the first bounding box attachment that contains the line segment, or null. When doing many checks, it is usually more efficient to only call this method if {@link #aabbIntersectsSegment(float, float, float, float)} returns true.
public IntersectsSegment ( float x1, float y1, float x2, float y2 ) : BoundingBoxAttachment
x1 float
y1 float
x2 float
y2 float
리턴 BoundingBoxAttachment
		public BoundingBoxAttachment IntersectsSegment (float x1, float y1, float x2, float y2) {
			ExposedList<Polygon> polygons = Polygons;
			for (int i = 0, n = polygons.Count; i < n; i++)
				if (IntersectsSegment(polygons.Items[i], x1, y1, x2, y2)) return BoundingBoxes.Items[i];
			return null;
		}

Same methods

SkeletonBounds::IntersectsSegment ( Polygon polygon, float x1, float y1, float x2, float y2 ) : bool