Implementing Processing to web problem
in
Processing with Other Languages
•
4 months ago
First i implementet it "inline" i took the example from this page
http://processingjs.nihongoresources.com/processing%20on%20the%20web/#inpage
and it worked.
but i want to load the code from a file like this example
but it dosen't work for me. Here is what I use:
(Index.html)
Html:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>My Processing Page</title>
<script type="text/javascript" src="processing.js"></script>
</head>
<body>
<canvas id="mysketch" data-processing-sources="mysketch.pde"/></canvas>
</body>
</html>
(mysketch.pde)
PDE:
void setup() {
size(200,200);
}
void draw() {
ellipse(10,10,10,10);
}
(processing.js)
1