LinearStep() 공개 정적인 메소드

public static LinearStep ( Double y0, Double y1, Double percent ) : Double
y0 Double
y1 Double
percent Double
리턴 Double
예제 #1
0
 public virtual void Draw(Double pPercent)
 {
     Node.Position    = new Vector3(Methods.CubicStep(ox, odx, x, dx, pPercent), Methods.CubicStep(oy, ody, y, dy, pPercent), 0);
     Node.Orientation =
         Quaternion.FromAngleAxis(Methods.CubicStep(oa, oda, a, da, pPercent) * Constants.DegreesToRadians, Vector3.UnitZ) *
         Quaternion.FromEulerAnglesInDegrees(-16 * Methods.LinearStep(oda, da, pPercent), 0.0, 0.0);
 }
예제 #2
0
 public void Draw(Double pPercent)
 {
     Node.Position = new Vector3(
         cameraOffset.x + Methods.CubicStep(x[framesBehind], dx[framesBehind], x[framesBehind - 1], dx[framesBehind - 1], pPercent),
         cameraOffset.y + Methods.CubicStep(y[framesBehind], dy[framesBehind], y[framesBehind - 1], dy[framesBehind - 1], pPercent),
         cameraOffset.z + 32 * Methods.LinearStep(target.OldVelocity.LengthSquared, target.Velocity.LengthSquared, pPercent));
     Node.LookAt(new Vector3(
                     Methods.CubicStep(x[framesBehind / 2 + 1], dx[framesBehind / 2 + 1], x[framesBehind / 2], dx[framesBehind / 2], pPercent),
                     Methods.CubicStep(y[framesBehind / 2 + 1], dy[framesBehind / 2 + 1], y[framesBehind / 2], dy[framesBehind / 2], pPercent),
                     0), TransformSpace.Parent);
 }