pub struct LightingBody {
pub radius: f64,
pub position: Qty3<dyn Dimension<Kind = dyn Kind, T = Z0, L = PInt<UInt<UTerm, B1>>, N = Z0, Th = Z0, M = Z0, J = Z0, I = Z0>, RootInertial>,
pub distance: f64,
pub half_angle: f64,
}Expand description
Apparent parameters of a celestial body as seen from the observer.
position carries Position<RootInertial>: the lighting state
is always computed against root-inertial source positions
(Sun / Moon / Earth at the simulation root), so the field is
statically tagged with the root-inertial phantom. A consumer that
holds a body’s Position<IntegrationFrame> cannot subtract it
from LightingBody.position without going through the typed
integration-origin shift first (RF.10).
Fields§
§radius: f64Mean equatorial radius (m).
position: Qty3<dyn Dimension<Kind = dyn Kind, T = Z0, L = PInt<UInt<UTerm, B1>>, N = Z0, Th = Z0, M = Z0, J = Z0, I = Z0>, RootInertial>Position of the body relative to the observer, in the simulation’s root inertial frame (m).
distance: f64Distance from observer to body (m).
half_angle: f64Apparent angular half-angle of body disk (rad).
Trait Implementations§
Source§impl Clone for LightingBody
impl Clone for LightingBody
Source§fn clone(&self) -> LightingBody
fn clone(&self) -> LightingBody
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LightingBody
impl Debug for LightingBody
Source§impl Default for LightingBody
impl Default for LightingBody
Source§fn default() -> LightingBody
fn default() -> LightingBody
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LightingBody
impl RefUnwindSafe for LightingBody
impl Send for LightingBody
impl Sync for LightingBody
impl Unpin for LightingBody
impl UnsafeUnpin for LightingBody
impl UnwindSafe for LightingBody
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.