protected IMemoryMirroring MirrorPpuRange(int sourceStartAddress, int sourceEndAddress, int mirrorStartAddress, int mirrorEndAddress) { IMemoryMirroring mirroring = this.PpuBus.SetMirroringRange(sourceStartAddress, sourceEndAddress, mirrorStartAddress, mirrorEndAddress); this.ppuMirrorings.Add(mirroring); return(mirroring); }
void IMemoryBus.RemoveMirroring(IMemoryMirroring mirroring) { MemoryMirroring mirroringToRemove = this.mirroringsArray.FirstOrDefault(m => m.SourceStartAddress == mirroring.SourceStartAddress && m.SourceSize == mirroring.SourceSize && m.MirrorStartAddress == mirroring.MirrorStartAddress && m.MirrorEndAddress == mirroring.MirrorEndAddress); if (mirroringToRemove != null) { this.mirrorings.Remove(mirroringToRemove); this.mirroringsArray = this.mirrorings.ToArray(); } }