PathMeasure.GetSegment(Single, Single, Path, Boolean) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Given a start and stop distance, return in dst the intervening segment(s).
[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
Parameters
- startD
- Single
- stopD
- Single
- dst
- Path
- startWithMoveTo
- Boolean
Returns
- Attributes
Remarks
Given a start and stop distance, return in dst the intervening segment(s). If the segment is zero-length, return false, else return true. startD and stopD are pinned to legal values (0..getLength()). If startD >= stopD then return false (and leave dst untouched). Begin the segment with a moveTo if startWithMoveTo is true.
On android.os.Build.VERSION_CODES#KITKAT
and earlier releases, the resulting path may not display on a hardware-accelerated Canvas. A simple workaround is to add a single operation to this path, such as dst.rLineTo(0, 0)
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.