Skip to content

Commit a3b6b0c

Browse files
authored
Merge pull request #18 from processing/ksen0-patch-3
Update README.md - scope of data.js
2 parents 50de381 + 8401805 commit a3b6b0c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ endShape();
235235

236236
The [custom shapes tutorial](https://p5js.org/tutorials/custom-shapes-and-smooth-curves/) has a bit more detail on this, but Bézier curves need multiple points. In p5.js 1.x, they use three control points. In p5.js 2.0, that number is set by `bezierOrder`. Then, in p5.js 1.x each `bezierVertex(...)` was actually a set of three points describing a smooth curve. In p5.js 2.0, each `bezierVertext(x, y)` is just one point; you need the first point to anchor, and each curve after that needs 3 points.
237237

238-
## …using non-JavaScript data structures and functions
238+
## …using data structures and functions that have improved alternatives
239239

240240
One bit change relates to data structures in JavaScript. The following funcitons have been removed in p5.js 2.0. These were originally in p5.js 1.x because, historically, they were also in Processing. However, p5.js is a JavaScript library, and JavaScript objects and key-value maps can be used instead of these functions:
241241

@@ -256,3 +256,5 @@ The below functions are also better supported in JavaScript itself:
256256
* `sort()`
257257
* `splice()`
258258
* `subset()`
259+
260+
Additionally, `touchStarted()/touchEnded()/touchMoved()` have been replaced with mouse events.

0 commit comments

Comments
 (0)