Table of Contents

Method GetContainmentRatio

Namespace
LMKit.Graphics.Geometry
Assembly
LM-Kit.NET.dll

GetContainmentRatio(IBounds)

Computes the containment ratio between this rectangle and another bounds object.

public double GetContainmentRatio(IBounds other)

Parameters

other IBounds

The other bounds to compare with.

Returns

double

A value in the range [0, 1] representing how much the smaller of the two rectangles is covered by their intersection, where 0 means no overlap and 1 means the smaller rectangle is fully contained in the intersection.

Exceptions

ArgumentNullException

Thrown when other is null.