Question

I've got a Processing sketch that I'd like to display on my site with Processing.js rather than as a Java applet, however I'm not sure it supports tabs - or classes. Does it need to be written as procedural script, or is there an <include> I can use - or another option?

Thanks

Was it helpful?

Solution

I've answered a Processing related question and used classes, but I simply pasted the class after the rest of the program. I don't know if this fully answer your question, but here's an example

Processing sketch preview

OTHER TIPS

You can also include multiple .pde files in the html canvas tag separated by spaces

<canvas data-processing-sources="hello-web.pde class.pde"></canvas>

mentioned near the top of this page: http://processingjs.org/reference/articles/jsQuickStart

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top