pub trait GaussianCov3dConfig {
type Field: Pod + Zeroable;
const FEATURE: &'static str;
// Required methods
fn from_rot_scale(rot: Quat, scale: Vec3) -> Self::Field;
fn to_rot_scale(field: &Self::Field) -> (Quat, Vec3);
}Expand description
The covariance 3D configuration of Gaussian.
Currently, there are three configurations:
- Rotation and scale
GaussianCov3dRotScaleConfig - Single precision
GaussianCov3dSingleConfig- Format: 6 *
f32 - Cannot be converted back to rotation and scale
- Format: 6 *
- Half precision
GaussianCov3dHalfConfig- Format: 6 *
f16 - Cannot be converted back to rotation and scale
- Format: 6 *
Required Associated Constants§
Sourceconst FEATURE: &'static str
const FEATURE: &'static str
The name of the configuration.
Must match the wesl::Feature name in the shader.
Required Associated Types§
Sourcetype Field: Pod + Zeroable
type Field: Pod + Zeroable
The GaussianPod field type.
Required Methods§
Sourcefn from_rot_scale(rot: Quat, scale: Vec3) -> Self::Field
fn from_rot_scale(rot: Quat, scale: Vec3) -> Self::Field
Create from Gaussian::rot and Gaussian::scale.
Sourcefn to_rot_scale(field: &Self::Field) -> (Quat, Vec3)
fn to_rot_scale(field: &Self::Field) -> (Quat, Vec3)
Convert the field to Gaussian::rot and Gaussian::scale.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.