예제 #1
0
        public void AddReleaseTable(InstrumentOscillatorTableMode mode, int time = 0, int amount = 0)
        {
            if (!mode.IsDefined())
            {
                throw new ArgumentOutOfRangeException("mode");
            }

            var table = new InstrumentOscillatorTable();

            table.mode   = mode;
            table.time   = time;
            table.amount = amount;
            mReleaseTable.Add(table);
        }
예제 #2
0
        public void InsertReleaseTable(int index, InstrumentOscillatorTableMode mode, int time = 0, int amount = 0)
        {
            if (index < 0 || index > mReleaseTable.Count)
            {
                throw new ArgumentOutOfRangeException("index");
            }

            if (!mode.IsDefined())
            {
                throw new ArgumentOutOfRangeException("mode");
            }

            var table = new InstrumentOscillatorTable();

            table.mode   = mode;
            table.time   = time;
            table.amount = amount;
            mReleaseTable.Insert(index, table);
        }