문제

I have a working Java code that I would like to visualize using processing. I also found the tutorial on how to include processing within eclipse and am also already able to create a canvas, etc.

What I want to do now is to actually do the visualization. I found a nice project that is exactly what I need. However, the author provides PDE files.

How can I include PDE files in my java project? Is that even possible?

도움이 되었습니까?

해결책

The PDE files that are available in that project are simply text files. You can either use them in your code directly, or better yet, try to understand what they're doing and adapt the code to your own purposes.

But to answer your question, you don't include PDE files in a Java project. You included the Processing library jars on your classpath, which give you access to things like the PApplet class. Then you can include a PApplet (which is just like a Processing sketch, in fact a Processing sketch is a PApplet) in your Java application and pass it whatever information you want.

More info here: http://processing.org/tutorials/eclipse/

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top