I'm using Eclipse as environment for my Processing experiments and have problems to use OpenGl in my sketches.
Currently I'm working on "something" that uses Andreas Koeberle’s surface library. Inside Processing OpenGl works like a charm, but I didn't manage to import the library into Eclipse.
Here's a stripped down example:
Code:
import surface.*;
public class surface3d extends processing.core.PApplet {
DoubleCone t;
public void setup(){
size(400,400,P3D);
t=new DoubleCone(g, 20, 20);
background(255);
}
public void draw(){
lights();
float Random_Stroke;
int vResolution = (int) random(10,100);
int hResolution = 100;
t=new DoubleCone(g, vResolution, hResolution);
translate(width/2,height/2);
rotateX(radians(frameCount));
rotateY(radians(frameCount));
rotateZ(radians(frameCount));
t.setScale(width/5);
Random_Stroke = random(1, 2);
strokeWeight(Random_Stroke);
stroke(0,3);
t.drawHorizontalLines();
}
}
and a screen of the external libraries I added.
I already tried to import the OpenGl library in several ways, but without luck. Any help is much appreciated.
--
Edit:
Got detailed instructions from a friend - 'll post a brief tutorial later.