fixes for processing.js compatibility