Chart3DPose
public struct Chart3DPoseCamera pose for 3D charts, expressed as azimuth (rotation around Y) and
inclination (tilt up/down). Swift Charts equivalent: Chart3DPose.
Mirrors Chart3DPose(azimuth: .degrees(20), inclination: .degrees(7)).
Remarks
Section titled “Remarks”Lives in the core ChartGuru package so ChartGuru.Chart can hold a pose
value directly without a type dependency on the 3D add-on. All interactive
rendering of the pose is performed by the ChartGuru.3D add-on.
Fields
Section titled “Fields”
AzimuthDegrees
Section titled “AzimuthDegrees”public float AzimuthDegreesRotation around the Y axis, in degrees. Positive values rotate left-to-right.
Returns
System.Single
InclinationDegrees
Section titled “InclinationDegrees”public float InclinationDegreesTilt up/down, in degrees. Positive values tilt the camera upward.
Returns
System.Single
Distance
Section titled “Distance”public float DistanceDistance from the chart origin to the camera (orbit radius). 0 lets the host choose.
Returns
System.Single
Default
Section titled “Default”public static readonly Chart3DPose DefaultDefault pose: three-quarter oblique, matches Swift Charts Chart3DPose.default.
Returns
ChartGuru.Chart3DPose
public static readonly Chart3DPose FrontFront elevation (looking straight along +Z).
Returns
ChartGuru.Chart3DPose
public static readonly Chart3DPose BackBack elevation.
Returns
ChartGuru.Chart3DPose
public static readonly Chart3DPose RightRight-side elevation.
Returns
ChartGuru.Chart3DPose
public static readonly Chart3DPose LeftLeft-side elevation.
Returns
ChartGuru.Chart3DPose
public static readonly Chart3DPose TopTop-down plan view.
Returns
ChartGuru.Chart3DPose
Bottom
Section titled “Bottom”public static readonly Chart3DPose BottomBottom-up plan view.
Returns
ChartGuru.Chart3DPose
Constructors
Section titled “Constructors”
Chart3DPose(float, float, float)
Section titled “Chart3DPose(float, float, float)”public Chart3DPose(float azimuthDegrees, float inclinationDegrees, float distance = 0)Creates an orbit-camera pose from azimuth and inclination angles in degrees plus distance from the pivot.
Parameters
| Name | Type |
|---|---|
azimuthDegrees |
System.Single |
inclinationDegrees |
System.Single |
distance |
System.Single |
Methods
Section titled “Methods”
Lerp(Chart3DPose, Chart3DPose, float)
Section titled “Lerp(Chart3DPose, Chart3DPose, float)”public static Chart3DPose Lerp(Chart3DPose a, Chart3DPose b, float t)Linear interpolation between two poses (for animations).
Parameters
| Name | Type |
|---|---|
a |
ChartGuru.Chart3DPose |
b |
ChartGuru.Chart3DPose |
t |
System.Single |
Returns
ChartGuru.Chart3DPose
ToCameraRotation()
Section titled “ToCameraRotation()”public Quaternion ToCameraRotation()Compose a world-space rotation for a camera orbiting the origin.
Returns
UnityEngine.Quaternion
ToCameraPosition(Vector3, float)
Section titled “ToCameraPosition(Vector3, float)”public Vector3 ToCameraPosition(Vector3 pivot, float radius)Compute the camera position on the orbit sphere with the given radius and pivot.
When ChartGuru.Chart3DPose.Distance is zero, the supplied radius is used.
Parameters
| Name | Type |
|---|---|
pivot |
UnityEngine.Vector3 |
radius |
System.Single |
Returns
UnityEngine.Vector3
Equals(Chart3DPose)
Section titled “Equals(Chart3DPose)”public bool Equals(Chart3DPose other)Parameters
| Name | Type |
|---|---|
other |
ChartGuru.Chart3DPose |
Returns
System.Boolean
Equals(object)
Section titled “Equals(object)”public override bool Equals(object obj)Parameters
| Name | Type |
|---|---|
obj |
System.Object |
Returns
System.Boolean
GetHashCode()
Section titled “GetHashCode()”public override int GetHashCode()Returns
System.Int32
ToString()
Section titled “ToString()”public override string ToString()Returns
System.String
Operators
Section titled “Operators”
operator ==(Chart3DPose, Chart3DPose)
Section titled “operator ==(Chart3DPose, Chart3DPose)”public static bool operator ==(Chart3DPose a, Chart3DPose b)Reports whether azimuth, inclination, and distance are approximately equal using Unity float tolerances.
Parameters
| Name | Type |
|---|---|
a |
ChartGuru.Chart3DPose |
b |
ChartGuru.Chart3DPose |
Returns
System.Boolean
operator !=(Chart3DPose, Chart3DPose)
Section titled “operator !=(Chart3DPose, Chart3DPose)”public static bool operator !=(Chart3DPose a, Chart3DPose b)Reports whether any orbit angle or distance differs beyond Unity float tolerances.
Parameters
| Name | Type |
|---|---|
a |
ChartGuru.Chart3DPose |
b |
ChartGuru.Chart3DPose |
Returns
System.Boolean