Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

A simple p5.js add-on to let you use input more efficiently. Just simply add to your code! An example is in the readme

Notifications You must be signed in to change notification settings

Buggem/processing.input

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

30 Commits

Repository files navigation

processing.input

A simple p5.js and Processing add-on to let you use input. Just simply add to your code!

Variables added

  • keysHeld is a array (an ArrayList in Processing) with all the keys pressed stored in it.
  • aKeyPressed is detecting when a key is pressed (just a merge of keyPressed in processing and keyIsPressed in p5.js basically so your projects are easier to convert to p5.js/processing)
  • theKey is the last key pressed.
  • keysLog is a string containing all keys ever pressed.

Add it

p5.js

Download the p5.input.js file and add

<script src="p5.input.js"></script>

to your code.

Processing (as of version 4)

Copy and paste the processing.input.pde file to your code.

Demo

There is a demonstration of p5.input.js and how it works here, as well as a demonstration using a emulated Java/Processing Environment here. It is also shown on the p5js libraries site.

About

A simple p5.js add-on to let you use input more efficiently. Just simply add to your code! An example is in the readme

Resources

Stars

Watchers

Forks

Packages

No packages published

AltStyle によって変換されたページ (->オリジナル) /