MCPcopy Create free account
hub / github.com/OxideEngine/Oxide / distance2

Function distance2

oxide_math/test/vector4.rs:109–125  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

107
108 #[test]
109 fn distance2() {
110 let new_vector_1 = vector4::Vector4 {
111 x: 3.0,
112 y: 4.0,
113 z: 5.0,
114 w: 6.0,
115 };
116 let new_vector_2 = vector4::Vector4 {
117 x: -3.0,
118 y: -4.0,
119 z: -5.0,
120 w: -6.0,
121 };
122 let target = 18.547_236_99;
123 let result = new_vector_1.distance(&new_vector_2);
124 assert_approx_eq!(target, result);
125 }
126
127 #[test]
128 fn clamp() {

Callers

nothing calls this directly

Calls 1

distanceMethod · 0.45

Tested by

no test coverage detected