Struct ARLightEstimationData
A structure for light estimation information provided by the AR device.
Namespace: UnityEngine.XR.ARFoundation
Syntax
public struct ARLightEstimationData : IEquatable<ARLightEstimationData>
Properties
averageBrightness
An estimate for the average brightness in the scene.
Use averageBrightness.HasValue to determine if this information is available.
Declaration
public float? averageBrightness { get; set; }
Property Value
| Type | Description |
|---|---|
| Nullable<Single> |
Remarks
averageBrightness may be null when light estimation is not enabled in the ARSession, or if a platform-specific error has occurred.
averageColorTemperature
An estimate for the average color temperature of the scene.
Use averageColorTemperature.HasValue to determine if this information is available.
Declaration
public float? averageColorTemperature { get; set; }
Property Value
| Type | Description |
|---|---|
| Nullable<Single> |
Remarks
averageColorTemperature may be null when light estimation is not enabled in the ARSession, if the platform does not support it, or if a platform-specific error has occurred.
averageIntensityInLumens
An estimate for the average intensity, in lumens, in the scene.
Use averageIntensityInLumens.HasValue to determine if this information is available.
Declaration
public float? averageIntensityInLumens { get; set; }
Property Value
| Type | Description |
|---|---|
| Nullable<Single> |
Remarks
averageIntensityInLumens may be null when light estimation is not enabled in the ARSession, or if a platform-specific error has occurred.
colorCorrection
The scaling factors used for color correction. The RGB scale factors are used to match the color of the light in the scene. The alpha channel value is platform-specific.
Declaration
public Color? colorCorrection { get; set; }
Property Value
| Type | Description |
|---|---|
| Nullable<Color> |
Remarks
colorCorrection may be null when light estimation is not enabled in the ARSession, if the platform does not support it, or if a platform-specific error has occurred.
Methods
Equals(Object)
Compares for equality.
Declaration
public override bool Equals(object obj)
Parameters
| Type | Name | Description |
|---|---|---|
| Object | obj | An |
Returns
| Type | Description |
|---|---|
| Boolean |
|
Overrides
Equals(ARLightEstimationData)
Compares for equality.
Declaration
public bool Equals(ARLightEstimationData other)
Parameters
| Type | Name | Description |
|---|---|---|
| ARLightEstimationData | other | The other ARLightEstimationData to compare against. |
Returns
| Type | Description |
|---|---|
| Boolean |
|
GetHashCode()
Generates a hash code suitable for use in HashSet and Dictionary.
Declaration
public override int GetHashCode()
Returns
| Type | Description |
|---|---|
| Int32 | A hash of the ARLightEstimationData. |
Overrides
ToString()
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| String |
Overrides
Operators
Equality(ARLightEstimationData, ARLightEstimationData)
Compares lhs and rhs for equality using Equals(ARLightEstimationData).
Declaration
public static bool operator ==(ARLightEstimationData lhs, ARLightEstimationData rhs)
Parameters
| Type | Name | Description |
|---|---|---|
| ARLightEstimationData | lhs | The left-hand-side ARLightEstimationData of the comparison. |
| ARLightEstimationData | rhs | The right-hand-side ARLightEstimationData of the comparison. |
Returns
| Type | Description |
|---|---|
| Boolean |
|
Inequality(ARLightEstimationData, ARLightEstimationData)
Compares lhs and rhs for inequality using Equals(ARLightEstimationData).
Declaration
public static bool operator !=(ARLightEstimationData lhs, ARLightEstimationData rhs)
Parameters
| Type | Name | Description |
|---|---|---|
| ARLightEstimationData | lhs | The left-hand-side ARLightEstimationData of the comparison. |
| ARLightEstimationData | rhs | The right-hand-side ARLightEstimationData of the comparison. |
Returns
| Type | Description |
|---|---|
| Boolean |
|