Esempio n. 1
0
        public bool TryGetSegment(double startDistance, double stopDistance, bool startOnBeginFigure,
                                  out IGeometryImpl segmentGeometry)
        {
            if (EffectivePath is null)
            {
                segmentGeometry = null;
                return(false);
            }

            segmentGeometry = null;

            var _skPathSegment = new SKPath();

            var res = CachedPathMeasure.GetSegment((float)startDistance, (float)stopDistance, _skPathSegment, startOnBeginFigure);

            if (res)
            {
                segmentGeometry = new StreamGeometryImpl(_skPathSegment);
            }

            return(res);
        }
 /// <summary>
 /// Initializes a new instance of the <see cref="StreamContext"/> class.
 /// <param name="geometryImpl">Geometry to operate on.</param>
 /// </summary>
 public StreamContext(StreamGeometryImpl geometryImpl)
 {
     _geometryImpl = geometryImpl;
     _path         = _geometryImpl._effectivePath;
 }
Esempio n. 3
0
 public StreamContext(StreamGeometryImpl geometryImpl)
 {
     _geometryImpl = geometryImpl;
     _path = _geometryImpl._path;
 }