[sc-users] Re: SwingOSC: unexpected behaviors

Sciss contact at sciss.de
Fri Mar 2 15:26:02 PST 2007


ciao andrea,

hmmm.... sounds you are having this problem:

http://www.create.ucsb.edu/pipermail/sc-users/2007-February/031810.html

however i remember luis saying that he finally solved the problem.

i'm on osx 10.4.8 with latest SC svn build (got my laptop back today,  
yesssss ;-)  and i don't have this problem. obviously sclang doesn't  
receive messages sent back from SwingOSC, but why? can you check out  
this code:

g = SwingOSC.default;
g.addr.isConnected; // --> should return true . if not, re-compile  
class lib or call g.connect; g.initTree;

r = OSCpathResponder( g.addr, [ '/info', 66666 ], { arg time, resp,  
msg; msg.postln; resp.remove; }).add;
g.sendMsg( '/query', 66666, '[', '/field',  
'de.sciss.swingosc.SwingOSC', \VERSION, ']' );  // --> should invoke  
the osc responder


?

ciao, -sciss-


Am 02.03.2007 um 14:45 schrieb Andrea Valle:

> Ciao Sciss,
>
> I'm now on macosx 10.4.8, shining new, with a sc fresh build and a  
> swingOSC 5.
>
> Actually this starts booting but fails
>
>
> SwingOSC.program = "java -jar /Applications/SuperCollider_f/ 
> SwingOSC.jar";
>
> g = SwingOSC.default
>
>
> g.boot
>
> booting java -jar /Applications/SuperCollider_f/SwingOSC.jar -t  
> 57111 -L -i
> SwingOSC v0.5. receiving TCP at address 127.0.0.1:57111
> ERROR:
> SwingOSC server failed to start
>
>
> If I boot from terminal,
>
> andrea-valles-computer:/Applications/SuperCollider_f andreavalle$  
> java -jar SwingOSC.jar -t 57111 -i -L
> SwingOSC v0.5. receiving TCP at address 127.0.0.1:57111
>
>
> it's fine. But when I evaluate this as a text (JKnob help)
>
>
> (
> var window, size = 32; // try different sizes - from 15 to 200 or  
> more!
> window = JSCWindow.new("Knob", Rect(300,300,270,100)).front;
> k = JKnob.new(window, Rect(20, 10, size, size));
> k.action_({|v,x,y,m| ["action func", v.value].postln; });
> //k.color[1] = Color.gray(alpha:0);
> )
>
> I have the knob, but it doesn't respond to mouse nor, of course, it  
> post values.
> Here (a classic from help file...) :
>
> (
> w = JSCWindow.new;
> b = JSCButton( w, Rect( 20, 20, 340, 30 ));
> b.states = [	// array of states
> 			[ "suffering", Color.black ],	// first state
> 			[ "origins of suffering", Color.white, Color.black ],  // second  
> state etc.
> 			[ "cessation of creating suffering", Color.red, Color.white ],
> 			[ "the path to cessation of creating suffering", Color.blue,  
> Color.clear ]
> 		];
> b.action = { arg button;
> 	button.value.postln;	
> };
> w.front;
> )
>
> JSCButton generates the button and toggles between states but  
> doesn't post on post window.
>
>
> Am I missing something obvious?
>
>
> Many thanks
>
>
> -a-
>
>
> Andrea Valle
>
> CIRMA - DAMS
> Università degli Studi di Torino
> --> http://www.semiotiche.it/andrea/
> --> andrea.valle at unito.it
>
>




More information about the sc-users mailing list