Beispiel #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="mediaStream"></param>
        public void Open(Stream mediaStream)
        {
            _isInternalStream = false;
            _mediaStream      = mediaStream;

            // Create the binary reader.
            _binaryReader = new BinaryReader(_mediaStream);
            _mux          = new VideoAudioMux(_binaryReader);

            // Create the audio player.
            _device      = Nequeo.IO.Audio.Devices.GetDevice(0);
            _audioPlayer = new IO.Audio.WavePlayer(_device);
        }
Beispiel #2
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="mediaFilename"></param>
        public void Open(string mediaFilename)
        {
            _isInternalStream = true;

            // Create the binary reader.
            _mediaStream  = new FileStream(mediaFilename, FileMode.Open, FileAccess.Read);
            _binaryReader = new BinaryReader(_mediaStream);
            _mux          = new VideoAudioMux(_binaryReader);

            // Create the audio player.
            _device      = Nequeo.IO.Audio.Devices.GetDevice(0);
            _audioPlayer = new IO.Audio.WavePlayer(_device);
        }