mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Initial mobile website check in
This commit is contained in:
@@ -0,0 +1,70 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<root>
|
||||
<name>new</name>
|
||||
|
||||
<category>Structure</category>
|
||||
|
||||
<subcategory></subcategory>
|
||||
|
||||
<usage>Web & Application</usage>
|
||||
|
||||
<example>
|
||||
<image></image>
|
||||
<code>
|
||||
HLine h1 = new HLine();
|
||||
float[] speeds = new float[3];
|
||||
float ypos;
|
||||
|
||||
void setup() {
|
||||
size(200, 200);
|
||||
speeds[0] = 0.1;
|
||||
speeds[1] = 2.0;
|
||||
speeds[2] = 0.5;
|
||||
}
|
||||
|
||||
void loop() {
|
||||
ypos += speeds[int(random(3))];
|
||||
if (ypos > width) {
|
||||
ypos = 0;
|
||||
}
|
||||
h1.update(ypos);
|
||||
}
|
||||
|
||||
class HLine {
|
||||
void update(float y) {
|
||||
line(0, y, width, y);
|
||||
}
|
||||
}
|
||||
</code>
|
||||
</example>
|
||||
|
||||
<description>
|
||||
Dynamically creates an object.
|
||||
</description>
|
||||
|
||||
<syntax>
|
||||
new
|
||||
</syntax>
|
||||
|
||||
<parameter>
|
||||
<label></label>
|
||||
</parameter>
|
||||
|
||||
<returns></returns>
|
||||
|
||||
<related></related>
|
||||
|
||||
<availability>1.0</availability>
|
||||
|
||||
<type>keyword</type>
|
||||
|
||||
<partof>PDE</partof>
|
||||
|
||||
<level>Extended</level>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</root>
|
||||
Reference in New Issue
Block a user