Loading...
Logo
Processing Forum
hi
i found this library:

it seems awesome!
but.. not going now.
i'm on processing 1.1
and with java 1.5

what can it be??
by the way, that sunflow seems to be no more developed, last news is in 2008

there are other ways to make render like that?
it seems to be a wrapper for a supercool renderer engine..
there are alternatives?

Copy code
  1. java.lang.NoSuchMethodException: hipstersinc.P5Sunflow.<init>()
  2. at java.lang.Class.getConstructor0(Class.java:2678)
  3. at java.lang.Class.getConstructor(Class.java:1629)
  4. at processing.core.PApplet.makeGraphics(PApplet.java:1315)
  5. at processing.core.PApplet.size(PApplet.java:1142)
  6. at processing.core.PApplet.size(PApplet.java:1102)
  7. at sketch_nov30a.setup(sketch_nov30a.java:81)
  8. at processing.core.PApplet.handleDraw(PApplet.java:1571)
  9. at processing.core.PApplet.run(PApplet.java:1496)
  10. at java.lang.Thread.run(Thread.java:613)
  11. processing.app.debug.RunnerException: RuntimeException: hipstersinc.P5Sunflow needs to be updated for the current release of Processing.
  12. at processing.app.Sketch.placeException(Sketch.java:1565)
  13. at processing.app.debug.Runner.findException(Runner.java:568)
  14. at processing.app.debug.Runner.reportException(Runner.java:543)
  15. at processing.app.debug.Runner.exception(Runner.java:498)
  16. at processing.app.debug.EventThread.exceptionEvent(EventThread.java:367)
  17. at processing.app.debug.EventThread.handleEvent(EventThread.java:255)
  18. at processing.app.debug.EventThread.run(EventThread.java:89)
  19. Exception in thread "Animation Thread" java.lang.RuntimeException: hipstersinc.P5Sunflow needs to be updated for the current release of Processing.
  20. at processing.core.PApplet.makeGraphics(PApplet.java:1368)
  21. at processing.core.PApplet.size(PApplet.java:1142)
  22. at processing.core.PApplet.size(PApplet.java:1102)
  23. at sketch_nov30a.setup(sketch_nov30a.java:81)
  24. at processing.core.PApplet.handleDraw(PApplet.java:1571)
  25. at processing.core.PApplet.run(PApplet.java:1496)
at java.lang.Thread.run(Thread.java:613)

Replies(4)

Can you post the code. I have it and it works fine with both 1.09 and 1.2.
the example in the homepage..

also with ubuntu i have the same problem!

Copy code
  1. void setup() {
  2.   //size(350, 200, P3D);
  3.   size(350, 200, "hipstersinc.P5Sunflow");
  4.   noLoop();
  5.   noStroke();
  6. }

  7. void draw() {
  8.   background(255);

  9.   int numSpheres = 4;
  10.   float yStep = width/4;
  11.   float y = 40;

  12.   for(int i=0; i<numSpheres; i++) {
  13.     pushMatrix();
  14.     translate(y, height/2);

  15.     fill( i*(255/numSpheres), random(100, 200), random(0, 100) );
  16.     sphere(40);
  17.     popMatrix();

  18.     y += yStep;
  19.   }
  20. }
The hipsterinc example also works fine for me (on Kubuntu 10.04). 
However I have also explored the SunflowAPIAPI and joons interfaces (all three include the sunflow library). 

This could potentially produce a conflict so I have created a separate sunflow folder in my libraries folder that contains the sunflow and janino jars (you will then need to add  import org.sunflow.*; to your sketch unless it is already included).

The joons interface currently requires the 0.07.2 version of sunflow (however with some modifications I've got it to work with version 0.07.3 use include instead of parse for the *.sc file see SunflowRenderer.java, and in the 0.07.3 version the cornell_box is considered to be a light so modify that to to get the examples to work), both the other interfaces require the 0.07.3 version.

Sunflow does not seem to have been updated for ages, and is incompatible with the current version of janino, however it is relatively simple to update sunflow (mainly drop a couple of Exception types and replace one with the commons-compiler version).

Interestingly both P5Sunflow and the new development P5SunflowAPIAPI fall foul of the edict thou shall not use P5 in your libraries name, perhaps there should be also be some advice about the inclusion of libraries where names and versions could conflict?