move Ferroxcube3R1MH from spirv_bindings to coremem_types::mat

This commit is contained in:
2022-07-18 15:33:47 -07:00
parent d005256459
commit 716e0e12b4
4 changed files with 23 additions and 22 deletions

View File

@@ -25,24 +25,6 @@ impl Material<f32> for FullyGenericMaterial {
}
}
/// MHPgram that's vaguely similar to Ferroxcube's 3R1 material
#[derive(Copy, Clone, Default, PartialEq)]
pub struct Ferroxcube3R1MH;
impl Into<MHPgram<f32>> for Ferroxcube3R1MH {
fn into(self) -> MHPgram<f32> {
// TODO: how much (if any) penalty do we pay for this not being `const`?
MHPgram::new(25.0, 881.33, 44000.0)
}
}
impl Material<f32> for Ferroxcube3R1MH {
fn move_b_vec(&self, m: Vec3<f32>, target_b: Vec3<f32>) -> Vec3<f32> {
let curve: MHPgram<f32> = (*self).into();
curve.move_b_vec(m, target_b)
}
}
/// Optimized material aimed at saving space for the common case of a simulation that contains
/// isomorphic conductors plus one exception material.
#[derive(Copy, Clone, Default, PartialEq)]