Пример #1
0
 public AY8910interface(int num, int baseclock, int[] mixing_level, AY8910portRead[] portAread, AY8910portRead[] portBread, AY8910portWrite[] portAwrite, AY8910portWrite[] portBwrite, AY8910handler[] handler)
 {
     this.num = num; this.baseclock = baseclock; this.mixing_level = mixing_level;
     this.portAread = portAread; this.portBread = portBread;
     this.portAwrite = portAwrite; this.portBwrite = portBwrite;
     this.handler = handler;
 }
Пример #2
0
        int AY8910_init(Mame.MachineSound msound, int chip, int clock, int volume, int sample_rate, AY8910portRead portAread, AY8910portRead portBread, AY8910portWrite portAwrite, AY8910portWrite portBwrite)
        {
            //AY8910 PSG = AYPSG[chip];

            string[] name = new string[3];
            int[] vol = new int[3];

            AYPSG[chip].SampleRate = sample_rate;
            AYPSG[chip].PortAread = portAread;
            AYPSG[chip].PortBread = portBread;
            AYPSG[chip].PortAwrite = portAwrite;
            AYPSG[chip].PortBwrite = portBwrite;
            for (int i = 0; i < 3; i++)
            {
                vol[i] = volume;
                name[i] = Mame.sprintf("%s #%d Ch %c", Mame.sound_name(msound), chip, 'A' + i);
            }
            AYPSG[chip].Channel = Mame.stream_init_multi(3, name, vol, sample_rate, chip, AY8910Update);

            if (AYPSG[chip].Channel == -1)
                return 1;

            AY8910_set_clock(chip, clock);
            AY8910_reset(chip);

            return 0;
        }
Пример #3
0
 public YM2203interface(int num, int baseclock, int[] mixing_level, AY8910portRead[] portAread, AY8910portRead[] portBread, AY8910portWrite[] portAwrite, AY8910portWrite[] portBwrite, AY8910handler[] handler)
     : base(num, baseclock, mixing_level, portAread, portBread, portAwrite, portBwrite, handler) { }