示例#1
0
        void IAudioOutput.SetTimingInfo(retro_system_timing timing)
        {
            int newSampleRate = (int)timing.sample_rate;

            if (newSampleRate == _sampleRate)
            {
                return;
            }
            _sampleRate = newSampleRate;
            _player?.SetSourceFormat(newSampleRate, 16, 2);
        }
示例#2
0
        void IAudioOutput.SetTimingInfo(retro_system_timing timing)
        {
            // If we are currently playing then we need to
            //  resume playbackafter recreating the device.
            bool wasPlaying = _isPlaying;

            CreateDirectSound((int)timing.sample_rate);
            if (wasPlaying)
            {
                Play();
            }
        }