-
-
Save markdekuijer/5dc2379dcf6a84dfbec7153d17f69b63 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
float Lerp(float val1, float val2, float t) | |
{ | |
return (1 - t) * val1 + t * val2; | |
} | |
xyz Lerp(xyz pos1, xyz pos2, float t) | |
{ | |
return x=Lerp(pos1.x,pos2.x,t) | |
y=Lerp(pos1.y, pos2.y,t) | |
z=Lerp(pos1.z, pos2.z,t) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment