コード例 #1
0
        public MetaEventPort(int aDelta, byte aType, AByteArray byteArray)
            : base(aDelta, aType)
        {
            int length = byteArray.ReadByte();

            byteArray.AddPosition(length);
        }
コード例 #2
0
        public MidiEventKeyPressure(int aDelta, byte aState, AByteArray aByteArray)
            : base(aDelta, aState, 0, 0)
        {
            int length = aByteArray.ReadByte();

            aByteArray.AddPosition(length);
        }
コード例 #3
0
        public KeySignature(int aDelta, byte aType, AByteArray byteArray)
            : base(aDelta, aType)
        {
            int length = byteArray.ReadByte();

            byteArray.AddPosition(length);
        }
コード例 #4
0
        public RiffChunkSmpl(string aId, UInt32 aSize, AByteArray aByteArray, RiffChunkList aParent)
            : base(aId, aSize, aByteArray, aParent)
        {
            aByteArray.AddPosition(( int )Size);

            informationList.Add("Sample Data:" + Size);
        }
コード例 #5
0
        public FormAiffSsnd(string aId, UInt32 aSize, AByteArray aByteArray, FormChunkList aParent)
            : base(aId, aSize, aByteArray, aParent)
        {
            offset    = aByteArray.ReadUInt32();
            blockSize = aByteArray.ReadUInt32();
            comment   = aByteArray.ReadString(( int )offset);

            dataSize = ( int )(Size - offset - 8);
            aByteArray.AddPosition(dataSize);

            informationList.Add("Offset:" + offset);
            informationList.Add("Block Size:" + blockSize);
            informationList.Add("Comment:" + comment);
        }
コード例 #6
0
        public MetaEventTempo(int aDelta, byte aType, AByteArray byteArray)
            : base(aDelta, aType)
        {
            int length = byteArray.ReadByte();

            if (length == 3)
            {
                byte data1 = byteArray.ReadByte();
                byte data2 = byteArray.ReadByte();
                byte data3 = byteArray.ReadByte();

                tempo = (( int )data1 << 16) | (( int )data2 << 8) | data3;
            }
            else
            {
                byteArray.AddPosition(3);
                Logger.Exception(new Exception());
            }
        }
コード例 #7
0
        private Byte bb;                // 32分レベルビートサブディビジョンの状況、⇒4分音符1個の内部にある32分音符の個数

        public MetaEventTimeSignature(int aDelta, Byte aType, AByteArray byteArray)
            : base(aDelta, aType)
        {
            int length = byteArray.ReadByte();

            if (length == 4)
            {
                nn = byteArray.ReadByte();
                Byte shift = byteArray.ReadByte();
                cc = byteArray.ReadByte();
                bb = byteArray.ReadByte();

                for (int i = 0; i < shift; i++)
                {
                    dd *= 2;
                }
            }
            else
            {
                byteArray.AddPosition(3);
                Logger.Exception(new Exception());
            }
        }
コード例 #8
0
 public FormAiffChan(string aId, UInt32 aSize, AByteArray aByteArray, FormChunkList aParent)
     : base(aId, aSize, aByteArray, aParent)
 {
     aByteArray.AddPosition(( int )Size);
 }
コード例 #9
0
 public RiffWaveData(string aId, UInt32 aSize, AByteArray aByteArray, RiffChunkList aParent)
     : base(aId, aSize, aByteArray, aParent)
 {
     aByteArray.AddPosition(( int )Size);
 }
コード例 #10
0
 public MetaEventTrackEnd(int aDelta, byte aType, AByteArray byteArray)
     : base(aDelta, aType)
 {
     byteArray.AddPosition(1);
 }