Struct PlaneBoundaryCollection
Represents a collection of concave BoundedPlane boundaries obtained from
Namespace: UnityEngine.XR.MagicLeap
Syntax
public struct PlaneBoundaryCollection : IEquatable<PlaneBoundaryCollection>
Remarks
Each Magic Leap plane can have multiple plane boundaries. This collection
represents the set of all boundaries associated with a particular plane.
Note that unlike most boundaries associated with BoundedPlanes,
these are not necessarily convex.
The plane boundaries are tied to native resources which are managed
by the MagicLeapPlaneSubsystem. Typically, a PlaneBoundaryCollection
is only valid until the next call to
Properties
count
The number of boundaries in this collection.
Declaration
public int count { get; }
Property Value
| Type | Description | 
|---|---|
| Int32 | 
Item[Int32]
Attempts to get the plane boundary at index  and, if successful, copies it to boundaryOut.
boundaryOut is resized or created using  if necessary.
Declaration
public PlaneBoundary this[int index] { get; }
Parameters
| Type | Name | Description | 
|---|---|---|
| Int32 | index | The index of the boundary to retrieve.  | 
Property Value
| Type | Description | 
|---|---|
| PlaneBoundary | 
  | 
Exceptions
| Type | Condition | 
|---|---|
| InvalidOperationException | Thrown if valid is   | 
| InvalidOperationException | Thrown if   | 
| ArgumentOutOfRangeException | Thrown if   | 
valid
Whether this collection is valid or not. Check for validity before using the index operator.
Declaration
public bool valid { get; }
Property Value
| Type | Description | 
|---|---|
| Boolean | 
Methods
Equals(Object)
IEquatable interface. Compares for equality.
Declaration
public override bool Equals(object obj)
Parameters
| Type | Name | Description | 
|---|---|---|
| Object | obj | The object to compare for equality.  | 
Returns
| Type | Description | 
|---|---|
| Boolean | 
  | 
Overrides
Equals(PlaneBoundaryCollection)
IEquatable interface. Comapres for equality.
Declaration
public bool Equals(PlaneBoundaryCollection other)
Parameters
| Type | Name | Description | 
|---|---|---|
| PlaneBoundaryCollection | other | The PlaneBoundaryCollection to compare against.  | 
Returns
| Type | Description | 
|---|---|
| Boolean | 
  | 
GetEnumerator()
Get an enumerator, compatible with a duck-typed foreach. You typically would not call
this directly, but is used by the compiler in a foreach statement.
Declaration
public PlaneBoundaryCollection.Enumerator GetEnumerator()
Returns
| Type | Description | 
|---|---|
| PlaneBoundaryCollection.Enumerator | An Enumerator compatible with a duck-typed foreach.  | 
GetHashCode()
Computes a hash code suitable for use in a Dictionary or HashSet.
Declaration
public override int GetHashCode()
Returns
| Type | Description | 
|---|---|
| Int32 | A hash code suitable for use in a   | 
Overrides
Operators
Equality(PlaneBoundaryCollection, PlaneBoundaryCollection)
Comapres for equality. Same as Equals(PlaneBoundaryCollection).
Declaration
public static bool operator ==(PlaneBoundaryCollection lhs, PlaneBoundaryCollection rhs)
Parameters
| Type | Name | Description | 
|---|---|---|
| PlaneBoundaryCollection | lhs | The left-hand side of the comparison.  | 
| PlaneBoundaryCollection | rhs | The right-hand side of the comparison.  | 
Returns
| Type | Description | 
|---|---|
| Boolean | 
  | 
Inequality(PlaneBoundaryCollection, PlaneBoundaryCollection)
Comapres for inequality. Same as !Equals(PlaneBoundaryCollection).
Declaration
public static bool operator !=(PlaneBoundaryCollection lhs, PlaneBoundaryCollection rhs)
Parameters
| Type | Name | Description | 
|---|---|---|
| PlaneBoundaryCollection | lhs | The left-hand side of the comparison.  | 
| PlaneBoundaryCollection | rhs | The right-hand side of the comparison.  | 
Returns
| Type | Description | 
|---|---|
| Boolean | 
  |