예제 #1
0
        public void PcmIsSetWhenLoopPointsNeedAlignment()
        {
            //A new pcm array is generated if it doesn't exist, so check that the array returned
            //is the same when calling multiple times
            GcAdpcmChannel channel = GetBuilder().WithLoop(true, 20, 40).WithLoopAlignment(15).WithLoopContext(20, 0, 0, 0).Build();

            Assert.Same(channel.GetPcmAudio(), channel.GetPcmAudio());
        }
예제 #2
0
        public void PcmIsNotSameAfterChangingAndRebuildingChannel()
        {
            GcAdpcmChannel channel  = GetBuilder().WithLoop(true, 10, 100).Build();
            GcAdpcmChannel channel2 = channel.GetCloneBuilder().WithLoopAlignment(15).Build();

            Assert.NotSame(channel.GetPcmAudio(), channel2.GetPcmAudio());
        }
예제 #3
0
        public void PcmIsSameAfterChangingNonCriticalParametersAndRebuildingChannel()
        {
            GcAdpcmChannel channel  = GetBuilder().WithLoop(true, 10, 100).Build();
            GcAdpcmChannel channel2 = channel.GetCloneBuilder().WithLoop(true, 20, 100).WithSamplesPerSeekTableEntry(20).Build();

            Assert.Same(channel.GetPcmAudio(), channel2.GetPcmAudio());
        }
예제 #4
0
        public void PcmIsSameAfterRebuildingChannel()
        {
            GcAdpcmChannel channel  = GetBuilder().WithLoop(true, 10, 100).Build();
            GcAdpcmChannel channel2 = channel.GetCloneBuilder().Build();

            Assert.Same(channel.GetPcmAudio(), channel2.GetPcmAudio());
        }
예제 #5
0
        public void PcmLengthIsCorrectAfterAlignmentAndUnalignment()
        {
            GcAdpcmChannel channel  = GetBuilder(100).WithLoop(true, 10, 100).WithLoopAlignment(15).Build();
            GcAdpcmChannel channel2 = channel.GetCloneBuilder().WithLoopAlignment(0).Build();

            Assert.Equal(105, channel.GetPcmAudio().Length);
            Assert.Equal(100, channel2.GetPcmAudio().Length);
        }
예제 #6
0
        public void PcmLengthIsCorrectAfterBuilding()
        {
            GcAdpcmChannel channel = GetBuilder(100).WithLoop(true, 10, 100).Build();

            Assert.Equal(100, channel.GetPcmAudio().Length);
        }
예제 #7
0
        public void PcmIsNotSetWhenSeekTableAndLoopContextNotNeeded()
        {
            GcAdpcmChannel channel = GetBuilder().WithLoop(true, 20, 40).WithLoopContext(20, 0, 0, 0).Build();

            Assert.NotSame(channel.GetPcmAudio(), channel.GetPcmAudio());
        }