Preloading problem with processing.js
in
Processing with Other Languages
•
7 months ago
I'm not able to load any kind of file when trying to put my processing sketch into a webpage.
Even the simplest program, like the one below, won't load anything, and I'm not able to point the problem. I've tried reading other people's similar topics, but the solutions they find don't seem to work for me.
mind that prova.jpg and processing.js are in the same directory.
what am I doing wrong?
Even the simplest program, like the one below, won't load anything, and I'm not able to point the problem. I've tried reading other people's similar topics, but the solutions they find don't seem to work for me.
mind that prova.jpg and processing.js are in the same directory.
what am I doing wrong?
- /* @pjs preload = "prova.jpg"; */
- void setup () {
- size (600, 600);
- PImage prova = requestImage("prova.jpg");
- }
- void draw () {
- background(0);
- image(prova, 0, 0);
- }
1