Struct XRCameraBackgroundRenderingParams
Describes the geometry and transform of the camera background for a given platform.
Implements
Inherited Members
Namespace: UnityEngine.XR.ARSubsystems
Assembly: Unity.XR.ARSubsystems.dll
Syntax
public readonly struct XRCameraBackgroundRenderingParams : IEquatable<XRCameraBackgroundRenderingParams>
Constructors
XRCameraBackgroundRenderingParams(Mesh, Matrix4x4)
Constructs a XRCameraBackgroundRenderingParams from a mesh and transform.
Declaration
public XRCameraBackgroundRenderingParams(Mesh mesh, Matrix4x4 transform)
Parameters
Type | Name | Description |
---|---|---|
Mesh | mesh | The geometry that should be used to render the camera background. Cannot be null. |
Matrix4x4 | transform | The transform that should be used to render the camera background. |
XRCameraBackgroundRenderingParams(Mesh, Matrix4x4, Matrix4x4, Matrix4x4)
Constructs a XRCameraBackgroundRenderingParams from a mesh and transform.
Declaration
public XRCameraBackgroundRenderingParams(Mesh mesh, Matrix4x4 model, Matrix4x4 view, Matrix4x4 projection)
Parameters
Type | Name | Description |
---|---|---|
Mesh | mesh | The geometry that should be used to render the camera background. Cannot be null. |
Matrix4x4 | model | The model matrix that should be used to render the camera background. |
Matrix4x4 | view | The view matrix that should be used to render the camera background. |
Matrix4x4 | projection | The projection matrix that should be used to render the camera background. |
Remarks
The model, view, and projection matrices are combined to form the transform.
Properties
backgroundGeometry
The geometry that should be used to render the camera background.
Declaration
public Mesh backgroundGeometry { get; }
Property Value
Type | Description |
---|---|
Mesh |
backgroundTransform
The transform that should be used to render the camera background.
Declaration
public Matrix4x4 backgroundTransform { get; }
Property Value
Type | Description |
---|---|
Matrix4x4 |
Methods
Equals(object)
Tests for equality.
Declaration
public override bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
object | obj | The |
Returns
Type | Description |
---|---|
bool | true if |
Overrides
Equals(XRCameraBackgroundRenderingParams)
Tests for equality.
Declaration
public bool Equals(XRCameraBackgroundRenderingParams other)
Parameters
Type | Name | Description |
---|---|---|
XRCameraBackgroundRenderingParams | other | The other XRCameraBackgroundRenderingParams to compare against. |
Returns
Type | Description |
---|---|
bool | true if every field in |
GetHashCode()
Generates a hash suitable for use with containers like HashSet
and Dictionary
.
Declaration
public override int GetHashCode()
Returns
Type | Description |
---|---|
int | A hash code generated from this object's fields. |
Overrides
Operators
operator ==(XRCameraBackgroundRenderingParams, XRCameraBackgroundRenderingParams)
Tests for equality. Same as Equals(XRCameraBackgroundRenderingParams).
Declaration
public static bool operator ==(XRCameraBackgroundRenderingParams lhs, XRCameraBackgroundRenderingParams rhs)
Parameters
Type | Name | Description |
---|---|---|
XRCameraBackgroundRenderingParams | lhs | The left-hand side of the comparison. |
XRCameraBackgroundRenderingParams | rhs | The right-hand side of the comparison. |
Returns
Type | Description |
---|---|
bool |
operator !=(XRCameraBackgroundRenderingParams, XRCameraBackgroundRenderingParams)
Tests for inequality. Same as !
Equals(XRCameraBackgroundRenderingParams).
Declaration
public static bool operator !=(XRCameraBackgroundRenderingParams lhs, XRCameraBackgroundRenderingParams rhs)
Parameters
Type | Name | Description |
---|---|---|
XRCameraBackgroundRenderingParams | lhs | The left-hand side of the comparison. |
XRCameraBackgroundRenderingParams | rhs | The right-hand side of the comparison. |
Returns
Type | Description |
---|---|
bool |