lerpFunctions:这个Swift Playground包含与线性插值有关的功能和演示功能

时间:2021-04-30 10:31:52
【文件属性】:
文件名称:lerpFunctions:这个Swift Playground包含与线性插值有关的功能和演示功能
文件大小:13KB
文件格式:ZIP
更新时间:2021-04-30 10:31:52
swift playground linear-algebra playgrounds lerp lerp功能 该Swift Playground包含与线性插值有关的功能,并演示了这些功能。 lerp 此功能演示了线性插值,使您可以沿两个已知点之间的路径查找未知点。 此函数使用三个参数: pointOne和pointTwo是Double值,而percentage是0.0到1.0之间的Double值。 此函数返回一个Double值,该值是沿pointOne和pointTwo之间的路径行进percentage 。 lerpRange 这个函数有三个参数: pointOne和pointTwo都是Double值,而percentages是阵列Double值表示百分数(之间0.0和1.0 )。 此函数返回一个Double值数组,该数组是按percentages数组中每个percentage值在两个提供的点之间进行插值的结果。 注意:如果在用例调用lerpRange传递给等间距的百分比数组,
【文件预览】:
lerpFunctions-master
----lerpFunctions.playground()
--------playground.xcworkspace()
--------timeline.xctimeline(2KB)
--------Contents.swift(5KB)
--------contents.xcplayground(196B)
----LICENSE(1KB)
----README.md(4KB)
----.gitattributes(65B)

网友评论