Syphon / Processing

Syphon Implementation for Processing
Other
137 stars 33 forks source link

Retiring a server at code unload time because it was not properly stopped #16

Closed clankill3r closed 2 years ago

clankill3r commented 10 years ago

If i stop the sketch (int IntelliJ) i get stuff like this:

2014-06-11 13:49:21.181 java[18352:8203] SYPHON DEBUG: SyphonServer: Retiring a server at code unload time because it was not properly stopped

In processing it's fine.

I saw there is already a dispose method:

This method is called automatically when the sketch is disposed, so making sure that the server is properly stopped and Syphon doesn't complain about memory not being properly released: https://github.com/Syphon/Processing/issues/4

For some reason if i run this in processing:

void setup() {
  registerMethod("dispose", this);
  registerMethod("exit", this);
  registerMethod("quit", this);
  registerMethod("stop", this);

}

void dispose() {
  println("dispose"); 
}

void exit() {
  println("exit"); 
}

void quit() {
  println("quit"); 
}

void stop() {
  println("stop"); 
}

Then dispose is printed when i start the sketch and exit is called when i close the sketch. So i was thinking of binding the dispose to exit. But for some reason exit does not called in IntelliJ (i also had this with eclipse before).

Maybe it's they way of closing that depends (a call to exit, pressing command + q, pressing the red close icon).

I don't know but there might be a fix for it.

codeanticode commented 7 years ago

@clankill3r could you check if this happens with the final 2.0 release?