Esempio n. 1
0
        public GameBoySpu(GameBoy device)
        {
            if (device == null)
            {
                throw new ArgumentNullException(nameof(device));
            }
            _device = device;
            var channels = new List <ISoundChannel>();

            channels.Add(null);
            channels.Add(null);
            channels.Add(Wave = new WaveSoundChannel());
            channels.Add(null);
            Channels = channels.AsReadOnly();
        }
Esempio n. 2
0
        public GameBoySpu(GameBoy device)
        {
            if (device == null)
            {
                throw new ArgumentNullException(nameof(device));
            }
            Device = device;
            var channels = new List <ISoundChannel>();

            channels.Add(new SquareSweepChannel(this));
            channels.Add(new SquareChannel(this));
            channels.Add(Wave = new WaveSoundChannel(this));
            channels.Add(new NoiseChannel(this));
            Channels = channels.AsReadOnly();
            ActivateAllChannels();
        }