I am still having some integration problems. yes i managed to make it run independently , but when i want it to run from an event i receive an exception.
The modification from the previous code i posted, despite having a main in the class i created the cunstructor to activate the PApplet
Code:
public Vizual() {
PApplet.main(new String[] { "--present", "Vizual" });
}
@Override
public void mousePressed() {
loop();
}
In my main application class i'm trying to get it start from an menu event:
Code:
if (command.equals(" Generate visualization ")) myviz = new Vizual();
Running the project, i recieve this when i try to "generate the visualization" from my menu .... and it crashes.
Code:
java.lang.ClassNotFoundException: Vizual
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at processing.core.PApplet.main(PApplet.java:6522)
at sphynxer.Vizual.<init>(Vizual.java:65)
And it's strange because i have the class "Vizual" defined
Code:
public class Vizual extends PApplet{
@Override
public void setup() {
size(400, 400, "prosvg.SVGKdl");
background(255);
noStroke();
smooth();
beginRecord(PDF, "pdf_export_test.pdf");
Any suggestions?