コード例 #1
0
ファイル: IccReader.cs プロジェクト: woutware/ImageSharp
        private IccTagTableEntry[] ReadTagTable(IccDataReader reader)
        {
            reader.SetIndex(128);   // An ICC header is 128 bytes long

            uint tagCount = reader.ReadUInt32();
            var  table    = new IccTagTableEntry[tagCount];

            for (int i = 0; i < tagCount; i++)
            {
                uint tagSignature = reader.ReadUInt32();
                uint tagOffset    = reader.ReadUInt32();
                uint tagSize      = reader.ReadUInt32();
                table[i] = new IccTagTableEntry((IccProfileTag)tagSignature, tagOffset, tagSize);
            }

            return(table);
        }