Advanced Drawing Techniques with UIBezierPath and Apple Pencil
summary
Walk-through code in Swift Playgrounds that actually builds a working drawing app using UIBezierPath and CAShapeLayer, showing line smoothing (quadratic/cubic choices and Catmull‑Rom mention), a measurable speed win by calling setNeedsDisplay(rect) instead of full redraw, and real Apple Pencil handling via touch.type == .stylus plus coalesced touches and predictive touches for low-latency rendering. Live demos show altitude/azimuth/force mapped to stroke width/shape, source code available, and the app successfully renders much smoother lines than naive point‑to‑point stroking.
AI-written summary · about
chapters (26)
- 0:00Intro
- 0:15ADVANCED DRAWING TECHNIQUES WITH VIBEZIERPATH AND APPLE PENCIL
- 1:23VECTOR GRAPHICS
- 2:13VECTOR CURVES
- 3:15BÉZIER BASICS
- 5:38QUADRATIC BÉZIER CURVE
- 6:19LINEAR CURVE
- 6:32HIGHER ORDER BÉZIER CURVES
- 6:48MOST COMMON BÉZIER CURVES
- 7:13MORE BÉZIER RESOURCES
- 7:39VIBEZIERPATH - LINES
- 9:24UIBEZIERPATH - SHAPES
- 9:55UIBEZIERPATH - DASH
- 17:16NSBEZIERPATH
- 20:08TOUCHESBEGAN
- 22:25DRAWRECT
- 22:43PERFORMANCE PROBLEMS
- 23:32PATH VS. STROKE
- 27:52DRAWING DEMO
- 28:10A LINE SMOOTHING ALGORITHM
- 31:25OTHER SMOOTHING ALGORITHMS
- 34:34CASHAPELAYER - RESOURCES
- 35:03APPLE PENCIL TRICKS
- 35:14DETECT APPLE PENCIL
- 38:02PREDICTED TOUCHES
- 40:19ALTITUDE AND AZIMUTH
related talks
10mPencilKit: From simple drawings to custom creative tools
41mCanvas Drawing for Fun and Profit
38mSpark Your Creativity: The Power of iPad Playgrounds
31mComposing in your Canvas!
26mExtending Manual Drawing Practices with Artist-Centric Programming Tools
22mDemo: Drawing Algorithms as Modular Objects: A Framework for Procedurally Generated(…)
34mMastering CustomPainter: Going Beyond Widgets in Flutter
32mEnhance your Flutter painting skills
