Beispiel #1
0
    // Use this for initialization
    void Start()
    {
        starWebrtcContext = StarWebrtcContext.CreateTraineeContext();
        // right after creating the context (before starting the connections), we could edit some parameters such as the signalling server

        //Messenger.AddListener<string>(SympleLog.LogTrace, OnLog);
        Messenger.AddListener <string>(SympleLog.LogDebug, OnLog);
        Messenger.AddListener <string>(SympleLog.LogInfo, OnLog);
        Messenger.AddListener <string>(SympleLog.LogError, OnLog);
    }
Beispiel #2
0
        public MainPage()
        {
            this.InitializeComponent();

            Debug.WriteLine("MainPage()");

            _mediaPlayer = new MediaPlayer();
            mediaPlayerElement.SetMediaPlayer(_mediaPlayer);

            starWebrtcContext = StarWebrtcContext.CreateTraineeContext();
            // right after creating the context (before starting the connections), we could edit some parameters such as the signalling server

            // comment these out if not needed
            //Messenger.AddListener<string>(SympleLog.LogTrace, OnLog);
            Messenger.AddListener <string>(SympleLog.LogDebug, OnLog);
            Messenger.AddListener <string>(SympleLog.LogInfo, OnLog);
            Messenger.AddListener <string>(SympleLog.LogError, OnLog);

            Messenger.AddListener <IMediaSource>(SympleLog.CreatedMediaSource, OnCreatedMediaSource);
            Messenger.AddListener(SympleLog.DestroyedMediaSource, OnDestroyedMediaSource);
        }