Move code

This commit is contained in:
Ali
2023-11-09 22:28:02 +04:00
parent f15c58c90a
commit 169fece59c
32 changed files with 4173 additions and 11 deletions

View File

@@ -0,0 +1,9 @@
import Foundation
func interpolateFloat(_ value1: Float, _ value2: Float, at factor: Float) -> Float {
return value1 * (1.0 - factor) + value2 * factor
}
func interpolatePoints(_ point1: SIMD2<Float>, _ point2: SIMD2<Float>, at factor: Float) -> SIMD2<Float> {
return SIMD2<Float>(x: interpolateFloat(point1.x, point2.x, at: factor), y: interpolateFloat(point1.y, point2.y, at: factor))
}