aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.HLE/Loaders/Npdm/KernelAccessControl.cs
blob: 611eda39f9d9511c7025baca7d1f040bbf74f636 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
using System.IO;

namespace Ryujinx.HLE.Loaders.Npdm
{
    class KernelAccessControl
    {
        public int[] Capabilities { get; private set; }

        public KernelAccessControl(Stream Stream, int Offset, int Size)
        {
            Stream.Seek(Offset, SeekOrigin.Begin);

            Capabilities = new int[Size / 4];

            BinaryReader Reader = new BinaryReader(Stream);

            for (int Index = 0; Index < Capabilities.Length; Index++)
            {
                Capabilities[Index] = Reader.ReadInt32();
            }
        }
    }
}