PathMeasure.GetSegment(Single, Single, Path, Boolean) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
給定起始與停止距離後,將中間段附加於 dst。
[Android.Runtime.Register("getSegment", "(FFLandroid/graphics/Path;Z)Z", "GetGetSegment_FFLandroid_graphics_Path_ZHandler")]
public virtual bool GetSegment(float startD, float stopD, Android.Graphics.Path? dst, bool startWithMoveTo);
[<Android.Runtime.Register("getSegment", "(FFLandroid/graphics/Path;Z)Z", "GetGetSegment_FFLandroid_graphics_Path_ZHandler")>]
abstract member GetSegment : single * single * Android.Graphics.Path * bool -> bool
override this.GetSegment : single * single * Android.Graphics.Path * bool -> bool
參數
- startD
- Single
- stopD
- Single
- dst
- Path
- startWithMoveTo
- Boolean
傳回
- 屬性
備註
給定起始與停止距離後,以 dst 返回中間段。 若段長度為零,則回傳 false,否則回傳 true。 startD 與 stopD 固定於法定值(0.getLength())。 若 startD >= 停止D,則回傳 false(並保持 dst 不變)。 如果 為真,則以 moveTo 開始該段。
在 android.os.Build.VERSION_CODES#KITKAT 及更早版本中,所得路徑可能無法在硬體加速的 Canvas 上顯示。 一個簡單的解決方法是在此路徑中加入單一操作,例如 dst.rLineTo(0, 0)。
Java 文件 android.graphics.PathMeasure.getSegment(float, float, android.graphics.Path, boolean)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。