We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpOther Libraries › OSCp5 used in eclipse: is it meant to work
Page Index Toggle Pages: 1
OSCp5 used in eclipse: is it meant to work? (Read 417 times)
OSCp5 used in eclipse: is it meant to work?
Mar 13th, 2008, 8:04pm
 
Hi!

I'm using OSCp5 to communicate over a network between a processing sketch, and a GUI that I'm creating using straight Java (no subclassing PApplet), coded in eclipse.

From within eclipse I just add oscp5.jar (0.9.3) as an external library to my project, along with core.jar, that I only add to avoid a crash that I otherwise got with OSCp5 when I started my app.

Since I am experiencing weird behavior however I was wondering, is using OSCp5 from a plain java app supposed to work, or should I expect funny behavior?

More specifically, the weird behavior I’m referring to is that when I close the java program in eclipse, in the debugger I can see that the app is still running, having two active threads…

Regards,
Ilias B.
Re: OSCp5 used in eclipse: is it meant to work?
Reply #1 - Mar 14th, 2008, 3:14am
 
hi,
you can use oscP5 in eclipse, thats what i do. to stop the thread created by oscP5 (the OSC Server, listenting for incoming messages) you can call oscP5.dispose(); when stopping your program. for example if you are running your own thread and you implement runnable, the stop() method would be a place to put oscP5.dispose();.
the crash you are encountering in eclipse when not importing core.jar happens in OscP5.java which needs to import core.PApplet. but i just figured i dont necessarily need it in there, so i will take it out and will update the changes here.
best,
andi
Re: OSCp5 used in eclipse: is it meant to work?
Reply #2 - Mar 14th, 2008, 1:04pm
 
Thanks for the quick reply! One could only wish for support like that on commercial software Tongue

Page Index Toggle Pages: 1