示例#1
0
        public Equalizer CreateEqualizer()
        {
            if (equalizers == null)
            {
                LoadEqualizers();
            }

            EqualizerRecord record    = new EqualizerRecord();
            Equalizer       equalizer = new Equalizer(record);

            equalizer_container_record.Add(record);
            equalizers.Add(equalizer);

            return(equalizer);
        }
示例#2
0
        public void Read(BinaryReader reader)
        {
            byte[] header = reader.ReadBytes(8);

            headerId = BitConverter.ToInt32(header, 0);
            int headerSize = BitConverter.ToInt32(header, 4);

            byte[] remainder = reader.ReadBytes(headerSize - 8);
            unknownOne = BitConverter.ToInt32(remainder, 0);
            unknownTwo = BitConverter.ToInt32(remainder, 4);
            int numEq = BitConverter.ToInt32(remainder, 8);

            eqSize = BitConverter.ToInt32(remainder, 12);

            for (int i = 0; i < numEq; i++)
            {
                EqualizerRecord eqrec = new EqualizerRecord();
                eqrec.Read(reader.ReadBytes(eqSize));

                Add(eqrec);
            }
        }
示例#3
0
 internal Equalizer(EqualizerRecord record)
 {
     this.record = record;
 }
示例#4
0
 public void Add(EqualizerRecord record)
 {
     equalizers.Add(record);
 }
示例#5
0
 public void Remove(EqualizerRecord record)
 {
     equalizers.Remove(record);
 }
示例#6
0
 public void Add(EqualizerRecord record)
 {
     equalizers.Add (record);
 }
示例#7
0
 internal Equalizer(EqualizerRecord record)
 {
     this.record = record;
 }
示例#8
0
 public void Remove(EqualizerRecord record)
 {
     equalizers.Remove (record);
 }
示例#9
0
        public void Read(BinaryReader reader)
        {
            byte[] header = reader.ReadBytes (8);

            headerId = BitConverter.ToInt32 (header, 0);
            int headerSize = BitConverter.ToInt32 (header, 4);

            byte[] remainder = reader.ReadBytes (headerSize - 8);
            unknownOne = BitConverter.ToInt32 (remainder, 0);
            unknownTwo = BitConverter.ToInt32 (remainder, 4);
            int numEq = BitConverter.ToInt32 (remainder, 8);
            eqSize = BitConverter.ToInt32 (remainder, 12);

            for (int i = 0; i < numEq; i++) {
                EqualizerRecord eqrec = new EqualizerRecord ();
                eqrec.Read (reader.ReadBytes (eqSize));

                Add (eqrec);
            }
        }
示例#10
0
文件: Device.cs 项目: mono/ipod-sharp
        public Equalizer CreateEqualizer()
        {
            if (equalizers == null) {
                LoadEqualizers ();
            }

            EqualizerRecord record = new EqualizerRecord ();
            Equalizer equalizer = new Equalizer (record);

            equalizer_container_record.Add (record);
            equalizers.Add (equalizer);

            return equalizer;
        }