Skip to content

Background transparency issue fixed...

F1LT3R edited this page Sep 12, 2010 · 2 revisions

As the context of a Processing.js app. is different from that of a Native Processing app, a clear() function was added to the Processing.js library.
In essence, this means you can clear the background of your Processing.js script to reveal the DOM elements behind.

I believe it is NOT possible to clear the background of Native Processing application to reveal the desktop. Go web!

Usage:

  1. clear(); – This clears the whole Canvas and reveals any elements or page-background behind the Canvas element.
  2. clear(x1, y1, x2, y2); – This clears a defined rectangle of the Canvas background from top-left to bottom-right;
Clone this wiki locally