How to make 3D with Processing core library

Hello,

I am using Eclipse Neon with W10.

This (your code with modifications) works:

Code
//package fr.ayfri;
import processing.core.PApplet;
import processing.core.PConstants;

public class MyProcessingSketch extends PApplet {

	public void settings() {
		size(200, 200, PConstants.P3D); // <--- P3D this tells Processing to work with 3D
		//textSize(64);	// Did not like it here!
	}
	
	public void draw() {
		background(140, 190, 255);
		textSize(64);	
		textAlign(CENTER, CENTER);
		text(":)", width/2, height/2 - 10);
	}
	
    public static void main(String[] args) {
		
	    String[] processingArgs = { "Main" };
	    MyProcessingSketch main = new MyProcessingSketch();
	    PApplet.runSketch(processingArgs, main);	
    }
}

:)

1 Like