201707-09 屏幕打印之printArray()函数 函数:printArray(); 释义:打印数组(); 即将数组打印在屏幕上。 举例: int A[] = {1,2,3,4,5,6}; void setup() { printArray(A); } void draw() { }  .... Read More >
201707-09 屏幕打印之println()函数 函数:println(); 释义:打印换行(); 即在屏幕上打印时自动换到另一行。 举例: void setup() { print("I love "); println("Processing."); println("It's so i.... Read More >
201707-09 noiseDetail() 名称:noiseDetail() 例子: float noiseVal; float noiseScale=0.02; void draw() { for (int y = 0; y < height; y++) { for (int x = 0; x < width/2; x++) { noiseDetail(3,0.5); noise.... Read More >
201707-09 noise() 噪音 名称:noise() 例子: float xoff = 0.0; void draw() { background(204); xoff = xoff + .01; float n = noise(xoff) * width; line(n, 0, n, height); } float noiseScale.... Read More >
201707-09 pixelDensity() 像素密度() 名称:pixelDensity() 例子: size(100, 100); pixelDensity(2); noStroke(); background(0); ellipse(30, 48, 36, 36); ellipse(70, 48, 36, 36); void setup() { size(100, 100); .... Read More >
201707-09 PShader 着色器 名称:PShader 例子: PShader blur; void setup() { size(640, 360, P2D); // Shaders files must be in the "data" folder to load correctly blur = loadShader("blur.glsl"); stroke(0, 102, 1.... Read More >
201707-09 sphere() 球 名称:sphere() 例子: noStroke(); lights(); translate(58, 48, 0); sphere(28); 描述: 球形是由镶嵌三角形制成的空心球。 &nb.... Read More >
201707-09 TWO_PI (2*π) 名称:TWO_PI 例子: float x = width/2; float y = height/2; float d = width * 0.8; arc(x.... Read More >
201707-09 TAU 名称:TAU 例子: float x = width/2; float y = height/2; float d = width * 0.8; arc(x, y.... Read More >
201707-09 QUARTER_PI (π/4) 名称:QUARTER_PI 例子: float x = width/2; float y = height/2; float d = width * 0.8; arc(x, y, d, d, 0, QUARTER_PI);.... Read More >
201707-09 PI (π) 名称:PI 例子: float x = width/2; float y = height/2; float d = width * 0.8; arc(x, y, d, d, 0, QUARTER_PI); arc(.... Read More >
201707-09 HAIF_PI (π/2) 名称:HALF_PI 例子: float x = width/2; float y = height/2; float d = width * 0.8; arc(x, y, d, d, 0, QUARTER_PI); .... Read More >