VelocityTracker.ComputeCurrentVelocity メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
オーバーロード
ComputeCurrentVelocity(Int32) |
Float の最大速度で を |
ComputeCurrentVelocity(Int32, Single) |
収集されたポイントに基づいて現在の速度を計算します。 |
ComputeCurrentVelocity(Int32)
Float の最大速度で を #computeCurrentVelocity(int, float)
呼び出すことと同じです。
[Android.Runtime.Register("computeCurrentVelocity", "(I)V", "")]
public void ComputeCurrentVelocity (int units);
[<Android.Runtime.Register("computeCurrentVelocity", "(I)V", "")>]
member this.ComputeCurrentVelocity : int -> unit
パラメーター
- units
- Int32
- 属性
注釈
Float.MAX_VALUEの最大速度で を #computeCurrentVelocity(int, float)
呼び出すことと同じです。
の android.view.VelocityTracker.computeCurrentVelocity(int)
Java ドキュメント。
このページの一部は、によって作成および共有された作業に基づく変更であり、に記載されている条件に従って使用されます。
こちらもご覧ください
- <xref:Android.Views.VelocityTracker.ComputeCurrentVelocity(System.Int32%2c+System.Single)>
適用対象
ComputeCurrentVelocity(Int32, Single)
収集されたポイントに基づいて現在の速度を計算します。
[Android.Runtime.Register("computeCurrentVelocity", "(IF)V", "")]
public void ComputeCurrentVelocity (int units, float maxVelocity);
[<Android.Runtime.Register("computeCurrentVelocity", "(IF)V", "")>]
member this.ComputeCurrentVelocity : int * single -> unit
パラメーター
- units
- Int32
速度を希望する単位。 値 1 は 1 ミリ秒あたりの単位、1000 は 1 秒あたりの単位数などを提供します。ここで参照する単位は、モーションが報告されるのと同じ単位であることに注意してください。 軸 X と Y の場合、単位はピクセルです。
- maxVelocity
- Single
このメソッドによって計算できる最大速度。 この値は units パラメーターと同じ単位で宣言する必要があります。 必ず正の値を指定します。
- 属性
注釈
収集されたポイントに基づいて現在の速度を計算します。 これは、速度情報を実際に取得する場合にのみ呼び出します。これは比較的高価であるためです。 その後、 と #getYVelocity()
を使用して速度を#getXVelocity()
取得できます。
の android.view.VelocityTracker.computeCurrentVelocity(int, float)
Java ドキュメント。
このページの一部は、によって作成および共有された作業に基づく変更であり、に記載されている条件に従って使用されます。