mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Added test for smooth on static for good measure.
This commit is contained in:
@@ -380,4 +380,9 @@ public class ParserTests {
|
||||
expectGood("smoothparam");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSmoothWithParamStatic() {
|
||||
expectGood("smoothparamstatic");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
import processing.core.*;
|
||||
import processing.data.*;
|
||||
import processing.event.*;
|
||||
import processing.opengl.*;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.ArrayList;
|
||||
import java.io.File;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.PrintWriter;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.io.IOException;
|
||||
|
||||
public class smoothparamstatic extends PApplet {
|
||||
|
||||
public void setup() {
|
||||
/* size commented out by preprocessor */;
|
||||
/* smooth commented out by preprocessor */;
|
||||
background(0);
|
||||
fill(255,0,0);
|
||||
ellipse(100,100,100,100);
|
||||
fill(0,255,0);
|
||||
ellipse(150,150,100,100);
|
||||
|
||||
noLoop();
|
||||
}
|
||||
|
||||
public void settings() { size(300, 300, P2D);
|
||||
smooth(4); }
|
||||
|
||||
static public void main(String[] passedArgs) {
|
||||
String[] appletArgs = new String[] { "smoothparamstatic" };
|
||||
if (passedArgs != null) {
|
||||
PApplet.main(concat(appletArgs, passedArgs));
|
||||
} else {
|
||||
PApplet.main(appletArgs);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
size(300,300, P2D);
|
||||
smooth(4);
|
||||
background(0);
|
||||
fill(255,0,0);
|
||||
ellipse(100,100,100,100);
|
||||
fill(0,255,0);
|
||||
ellipse(150,150,100,100);
|
||||
Reference in New Issue
Block a user