mirror of
https://github.com/processing/processing4.git
synced 2026-02-12 10:00:42 +01:00
74 lines
933 B
XML
74 lines
933 B
XML
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
|
<root>
|
|
<name>noLoop()</name>
|
|
|
|
<category>Structure</category>
|
|
|
|
<subcategory></subcategory>
|
|
|
|
<usage>Web & Application</usage>
|
|
|
|
<example>
|
|
<image></image>
|
|
<applet></applet>
|
|
<code>
|
|
void setup() {
|
|
size(200, 200);
|
|
noLoop();
|
|
}
|
|
|
|
float x = 0;
|
|
|
|
void draw() {
|
|
background(204);
|
|
x = x + .1;
|
|
if (x > width) {
|
|
x = 0;
|
|
}
|
|
line(x, 0, x, height);
|
|
}
|
|
|
|
void mousePressed() {
|
|
loop();
|
|
}
|
|
|
|
void mouseReleased() {
|
|
noLoop();
|
|
}
|
|
</code>
|
|
</example>
|
|
|
|
<description>
|
|
Stops Processing from continuously executing the code within <b>draw()</b>. If <b>loop()</b> is called, the code in <b>draw()</b> is executed continuously.
|
|
</description>
|
|
|
|
<syntax>
|
|
noLoop()
|
|
</syntax>
|
|
|
|
<parameter>
|
|
<label></label>
|
|
<description></description>
|
|
</parameter>
|
|
|
|
<returns>None</returns>
|
|
|
|
<related>
|
|
loop()
|
|
</related>
|
|
|
|
<availability>1.0</availability>
|
|
|
|
<type>Function</type>
|
|
|
|
<partof>PDE</partof>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</root>
|