audio
Class VideoServer

java.lang.Object
  extended by audio.VideoServer

public class VideoServer
extends java.lang.Object

Used internally to represent a connection to a VideoProcessor object that may or may not be running on the same computer.


Constructor Summary
VideoServer(Logger logger)
           
 
Method Summary
 void cancelConnect()
          Stops listening for positive responses to the 'are you alive' question.
 boolean connect()
          Connects to a remote VideoProcessor object.
 void disconnect()
          Disconnects from the remote machine - that is, it stops listening for traffic..
 boolean getConnected()
           
 int getControlPort()
           
 java.lang.String getCurrentlyRunningModuleName()
           
 java.lang.String getHostName()
           
 int getLocalControlPort()
           
 int getOSCPort()
          .
 boolean isConnecting()
           
 void send(com.illposed.osc.OSCMessage message)
          Sends an OSC message.
 void sendVideoInterfaceModule(VideoOutputModule videoInterfaceModule)
          Sends a VideoInterfaceModule to the remove VideoProcessor.
 void setConnected(boolean status)
          Sets whether or not we are currently connected.
 void setConnecting(boolean connecting)
          Sets whether or not we are connecting.
 void setControlPort(int controlPort)
          Sets the control port on the remote VideoProcessor.
 void setCurrentlyRunningModuleName(java.lang.String newName)
          Sets the name of the module currently running on the remove VideoProcessor.
 void setHostName(java.lang.String hostName)
          Sets the host name of the host running the remote VideoProcessor.
 void setLocalControlPort(int controlPort)
          Sets the local port used to listen for control messages.
 void setOSCPort(int port)
          Sets the OSC port number of the remote VideoProcessor.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VideoServer

public VideoServer(Logger logger)
Parameters:
logger -
Method Detail

getLocalControlPort

public int getLocalControlPort()
Returns:
The local port that listens for control messages.

setLocalControlPort

public void setLocalControlPort(int controlPort)
Sets the local port used to listen for control messages.

Parameters:
controlPort -

getControlPort

public int getControlPort()
Returns:
The control port on the remote VideoProcessor.

setControlPort

public void setControlPort(int controlPort)
Sets the control port on the remote VideoProcessor.

Parameters:
controlPort -

getHostName

public java.lang.String getHostName()
Returns:
The host name of the host running the remote VideoProcessor. Can be an IP address.

setHostName

public void setHostName(java.lang.String hostName)
Sets the host name of the host running the remote VideoProcessor. Can be an IP address.

Parameters:
hostName -

getOSCPort

public int getOSCPort()
.

Returns:
The OSC port number of the remote VideoProcessor

setOSCPort

public void setOSCPort(int port)
Sets the OSC port number of the remote VideoProcessor.

Parameters:
port -

send

public void send(com.illposed.osc.OSCMessage message)
Sends an OSC message.

Parameters:
message -

connect

public boolean connect()
Connects to a remote VideoProcessor object. It does this by sending a ControlMessage asking whether or not it is alive. Responses are received by an associated VideoServerChecker object that runs in a concurrent thread.

Returns:
Whether connection was successful.

disconnect

public void disconnect()
Disconnects from the remote machine - that is, it stops listening for traffic..


cancelConnect

public void cancelConnect()
Stops listening for positive responses to the 'are you alive' question.


getConnected

public boolean getConnected()
Returns:
whether or not we are currently connected.

setConnected

public void setConnected(boolean status)
Sets whether or not we are currently connected.

Parameters:
status -

isConnecting

public boolean isConnecting()
Returns:
True while we are trying to connect, but have yet to receive a positive response.

setConnecting

public void setConnecting(boolean connecting)
Sets whether or not we are connecting.

Parameters:
connecting -

getCurrentlyRunningModuleName

public java.lang.String getCurrentlyRunningModuleName()
Returns:
The name of the module currently running on the remove VideoProcessor.

setCurrentlyRunningModuleName

public void setCurrentlyRunningModuleName(java.lang.String newName)
Sets the name of the module currently running on the remove VideoProcessor.

Parameters:
newName -

sendVideoInterfaceModule

public void sendVideoInterfaceModule(VideoOutputModule videoInterfaceModule)
Sends a VideoInterfaceModule to the remove VideoProcessor.

Parameters:
videoInterfaceModule -