There isn’t that much precision in f32...
This commit is contained in:
parent
cc39a249b7
commit
64d53cf72b
|
|
@ -15,7 +15,7 @@ pub trait Metric {
|
|||
}
|
||||
|
||||
fn part_derivs_at(&self, pos: Vec3) -> Tens3 {
|
||||
part_deriv(|p| self.at(p), pos, 1.0 / 1024.0) // division by such eps is exact which is good for overall precision
|
||||
part_deriv(|p| self.at(p), pos, 1.0 / 64.0) // there just isn’t enough precision for a small ε.
|
||||
}
|
||||
|
||||
fn vec_length_at(&self, at: Vec3, v: Vec3) -> f32 {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user