50 #ifndef _FormatterActiveDevice_H_
51 #define _FormatterActiveDevice_H_
52 #include "FormatterMultiDevice.h"
54 #include "util/functions.h"
55 #include "util/Base64.h"
56 using namespace ::br::pucrio::telemidia::util;
59 #include "player/INCLPlayer.h"
60 using namespace ::br::pucrio::telemidia::ginga::core::player;
62 #include "system/compat/SystemCompat.h"
63 #include "system/compat/PracticalSocket.h"
64 using namespace ::br::pucrio::telemidia::ginga::core::system::compat;
66 #include "gingancl/privatebase/IPrivateBaseManager.h"
67 using namespace ::br::pucrio::telemidia::ginga::ncl;
73 #include <sys/types.h>
82 namespace multidevice {
86 static const unsigned int ADD_DOCUMENT = 10081;
87 static const unsigned int REMOVE_DOCUMENT = 10082;
88 static const unsigned int START_DOCUMENT = 10083;
89 static const unsigned int STOP_DOCUMENT = 10084;
90 static const unsigned int PAUSE_DOCUMENT = 10085;
91 static const unsigned int RESUME_DOCUMENT = 10086;
92 static const unsigned int SET_VAR = 10087;
93 static const unsigned int SELECTION = 10088;
96 static const unsigned int RCVBUFSIZE = 100;
98 static const string IMG_DIR;
99 static const string IMG_DEV;
100 static const string IMG_RESET;
101 static string TMP_DIR;
104 TCPSocket* tcpSocket;
105 int deviceServicePort;
109 map<string, string>* contentsInfo;
110 map<string, string> initVars;
112 string currentDocUri;
114 INCLPlayer* formatter;
120 GingaScreenID screenId,
121 IDeviceLayout* deviceLayout,
122 int x,
int y,
int w,
int h,
bool useMulticast,
int srvPort);
127 bool newDeviceConnected(
int newDevClass,
int w,
int h) {
131 bool socketSend(TCPSocket* sock,
string payload);
132 void connectedToBaseDevice(
unsigned int domainAddr);
133 bool receiveRemoteEvent(
136 string eventContent);
138 bool receiveRemoteContent(
140 char *stream,
int streamSize) {
145 bool receiveRemoteContent(
int remoteDevClass,
string contentUri);
146 bool receiveRemoteContentInfo(
string contentId,
string contentUri);
147 bool userEventReceived(IInputEvent* ev);
149 bool openDocument(
string contentUri);
150 INCLPlayer* createNCLPlayer();
153 int getCommandCode(
string *com);
154 void handleTCPClient(TCPSocket *sock);
155 bool handleTCPCommand(
159 string spayload_desc,
Definition: IPrivateBaseManager.h:61
Definition: INCLPlayer.h:63
Definition: FormatterActiveDevice.h:83
HAVE_MULTIDEVICE.
Definition: FormatterMultiDevice.h:121