public VideoSuscribeWindow(GUISkin skin, RoomVariableManager rvm, Texture2D videoDef, Texture2D videoTimeOut) { gSkin = skin; RoomVariableMgr = rvm; windowsCreated = false; adviceMessage = "No se selecciono usuario"; endSuscriptionMessage = "Terminar suscripcion"; endSuscriptionQuestion = "Desea terminar la suscripcion?"; videoFrame = new VidFrame(false); videoRunning = false; adviceWindowOn = false; closeQuestionOn = false; totalWidth = 500; menuWidth = totalWidth/3; listWidth = totalWidth-menuWidth; totalHeight = 400; conectionsList = new List<GUIContent>(); userScrollPosition = Vector2.zero; conectionScrollPosition = Vector2.zero; selectedConection = -1; tempSelectedConection = -1; selectedUser = -1; tempSelectedUser = -1; videoDefault = videoDef; enableWindow = false; timedOut = false; videoTimedOut = videoTimeOut; countDownTimer = new CountDownTimer(10); }
// Use this for initialization void Start() { senderIP = "127.0.0.1"; cantTransferMessage = "No se puede transmitir porque no autorizo la camara web."; endTransferenceMessage = "Terminar transferencia"; endTransferenceQuestion = "Desea terminar la transferencia?"; startCallMessage = "Iniciar llamada"; windowsCreated = false; videoTransmitting = false; videoRunning = false; endTransferOn = false; videoSuscribeWindowOn = false; authorized = true; widthPanel = 450; heightPanel = 180; if (SmartFoxConnection.IsInitialized){ smartFox = SmartFoxConnection.Connection; currentActiveRoom = smartFox.LastJoinedRoom; RoomVariableMgr = new RoomVariableManager(smartFox,currentActiveRoom); } webcam = new WebCamTexture(320,240,10); pix = new Color32 [webcam.width * webcam.height]; texturaVideo = new Texture2D(320,240,TextureFormat.RGB24,false); myVideoTexture = new Texture2D(320,240,TextureFormat.RGB24,false); videoRect = new Rect(screenH/9,screenW/9,320,240); videoFrame = new VidFrame(false); myVideoFrame = new VidFrame(true); jpgc = GameObject.Find("VideoProcessor").GetComponent<JPGConector>(); videoSuscribeWindow = new VideoSuscribeWindow(gSkin, RoomVariableMgr, videoDefault, videoTimeOut); buttonEnable=true; }