mirror of
https://github.com/GLEGram/GLEGram-iOS.git
synced 2026-04-30 23:08:10 +02:00
4647310322
Based on Swiftgram 12.5 (Telegram iOS 12.5). All GLEGram features ported and organized in GLEGram/ folder. Features: Ghost Mode, Saved Deleted Messages, Content Protection Bypass, Font Replacement, Fake Profile, Chat Export, Plugin System, and more. See CHANGELOG_12.5.md for full details.
10 lines
399 B
Swift
10 lines
399 B
Swift
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))
|
|
}
|