• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IO.FileSegmentGroup类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中Blamite.IO.FileSegmentGroup的典型用法代码示例。如果您正苦于以下问题:C# FileSegmentGroup类的具体用法?C# FileSegmentGroup怎么用?C# FileSegmentGroup使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



FileSegmentGroup类属于Blamite.IO命名空间,在下文中一共展示了FileSegmentGroup类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ThirdGenLanguageGlobals

        public ThirdGenLanguageGlobals(StructureValueCollection values, FileSegmenter segmenter, IPointerConverter localePointerConverter, BuildInformation buildInfo)
        {
            LocaleArea = new FileSegmentGroup(localePointerConverter);

            _languages = LoadLanguages(values, segmenter, buildInfo);
            _alignment = buildInfo.SegmentAlignment;
        }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:7,代码来源:ThirdGenLanguageGlobals.cs


示例2: ReflexiveData

 public ReflexiveData(string name, uint offset, uint address, uint entrySize, uint pluginLine, FileSegmentGroup metaArea)
     : base(name, offset, address, pluginLine)
 {
     _entrySize = entrySize;
     _metaArea = metaArea;
     _expanded = true;
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:7,代码来源:ReflexiveData.cs


示例3: WriteReflexive

        /// <summary>
        ///     Writes data to a reflexive, reallocating the original.
        /// </summary>
        /// <param name="entries">The entries to write.</param>
        /// <param name="oldCount">The old count.</param>
        /// <param name="oldAddress">The old address.</param>
        /// <param name="newCount">The number of entries to write.</param>
        /// <param name="layout">The layout of the data to write.</param>
        /// <param name="metaArea">The meta area of the cache file.</param>
        /// <param name="allocator">The cache file's meta allocator.</param>
        /// <param name="stream">The stream to manipulate.</param>
        /// <returns>The address of the new reflexive, or 0 if the entry list is empty and the reflexive was freed.</returns>
        public static uint WriteReflexive(IEnumerable<StructureValueCollection> entries, int oldCount, uint oldAddress,
			int newCount, StructureLayout layout, FileSegmentGroup metaArea, MetaAllocator allocator, IStream stream)
        {
            if (newCount == 0)
            {
                // Free the old reflexive and return
                if (oldCount > 0 && oldAddress != 0)
                    allocator.Free(oldAddress, oldCount*layout.Size);
                return 0;
            }

            uint newAddress = oldAddress;
            if (newCount != oldCount)
            {
                // Reallocate the reflexive
                int oldSize = oldCount*layout.Size;
                int newSize = newCount*layout.Size;
                if (oldCount > 0 && oldAddress != 0)
                    newAddress = allocator.Reallocate(oldAddress, oldSize, newSize, stream);
                else
                    newAddress = allocator.Allocate(newSize, stream);
            }

            // Write the new values
            WriteReflexive(entries.Take(newCount), newAddress, layout, metaArea, stream);
            return newAddress;
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:39,代码来源:ReflexiveWriter.cs


示例4: Load

		private void Load(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea,
			EngineDescription buildInfo)
		{
			Name = new StringID(values.GetInteger("name stringid"));

			LoadPermutations(values, reader, metaArea, buildInfo);
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:7,代码来源:FourthGenModelRegion.cs


示例5: Load

        private void Load(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, BuildInformation buildInfo)
        {
            ResourceIndex = new DatumIndex(values.GetInteger("resource datum index"));

            LoadRegions(values, reader, metaArea, buildInfo);
            LoadSections(values, reader, metaArea, buildInfo);
            LoadBoundingBox(values, reader, metaArea, buildInfo);
        }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:8,代码来源:ThirdGenRenderModel.cs


示例6: FourthGenResourceLayoutTable

		public FourthGenResourceLayoutTable(ITag playTag, FileSegmentGroup metaArea, MetaAllocator allocator,
			EngineDescription buildInfo)
		{
			_tag = playTag;
			_metaArea = metaArea;
			_allocator = allocator;
			_buildInfo = buildInfo;
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:8,代码来源:FourthGenResourceLayoutTable.cs


示例7: ReadObjects

 /// <summary>
 /// Reads all child objects of this reflexive.
 /// </summary>
 /// <param name="values">The values read from the parent.</param>
 /// <param name="reader">The stream to read from.</param>
 /// <param name="metaArea">The meta area of the cache file.</param>
 /// <param name="stringIDs">The string ID source for the cache file.</param>
 /// <param name="buildInfo">The build info for the cache file.</param>
 /// <returns>The objects that were read.</returns>
 public ScriptObject[] ReadObjects(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, StringIDSource stringIDs, BuildInformation buildInfo)
 {
     int count = (int)values.GetInteger(_countEntryName);
     uint address = (uint)values.GetInteger(_addressEntryName);
     var layout = buildInfo.GetLayout(_layoutName);
     var entries = ReflexiveReader.ReadReflexive(reader, count, address, layout, metaArea);
     return entries.Select(e => ReadScriptObject(e, reader, metaArea, stringIDs, buildInfo)).ToArray();
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:17,代码来源:ScriptObjectReflexive.cs


示例8: Load

		private void Load(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea,
			EngineDescription buildInfo)
		{
			ModelResourceIndex = new DatumIndex(values.GetInteger("model resource datum index"));

			LoadSections(values, reader, metaArea, buildInfo);
			LoadBoundingBoxes(values, reader, metaArea, buildInfo);
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:8,代码来源:FourthGenScenarioBSP.cs


示例9: SegmentPointer

 private SegmentPointer(FileSegment baseSegment, FileSegmentGroup baseGroup, int baseSegmentDelta)
 {
     _baseSegment = baseSegment;
     _baseGroup = baseGroup;
     _baseSegmentDelta = baseSegmentDelta;
     _originalBaseSize = baseSegment.Size;
     _baseBottomResizes = (baseSegment.ResizeOrigin == SegmentResizeOrigin.Beginning);
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:8,代码来源:SegmentPointer.cs


示例10: ThirdGenLanguage

        public ThirdGenLanguage(GameLanguage language, StructureValueCollection values, FileSegmenter segmenter,
			FileSegmentGroup localeArea, EngineDescription buildInfo)
        {
            Language = language;
            _pointerLayout = buildInfo.Layouts.GetLayout("locale index table entry");
            _encryptionKey = buildInfo.LocaleKey;
            _sizeAlign = (_encryptionKey != null) ? AES.BlockSize : 1;
            Load(values, segmenter, localeArea);
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:9,代码来源:ThirdGenLanguage.cs


示例11: LoadSoundNames

		private void LoadSoundNames(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, EngineDescription buildInfo)
		{
			var count = (int)values.GetInteger("number of sound names");
			var address = values.GetInteger("sound name table address");
			var layout = buildInfo.Layouts.GetLayout("sound names");
			var entries = ReflexiveReader.ReadReflexive(reader, count, address, layout, metaArea);

			SoundNames = entries.Select(e => new StringID(e.GetInteger("name index"))).ToArray();
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:9,代码来源:FourthGenSoundResourceGestalt.cs


示例12: Load

        private void Load(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, BuildInformation buildInfo)
        {
            VertexFormat = (int)values.GetInteger("vertex format");
            ExtraElementsPerVertex = (int)values.GetInteger("extra elements per vertex");
            ExtraElementsType = (ExtraVertexElementType)values.GetInteger("extra element type");

            LoadSubmeshes(values, reader, metaArea, buildInfo);
            LoadVertexGroups(values, reader, metaArea, buildInfo, Submeshes);
        }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:9,代码来源:ThirdGenModelSection.cs


示例13: ThirdGenLanguage

 public ThirdGenLanguage(StructureValueCollection values, FileSegmenter segmenter, FileSegmentGroup localeArea, BuildInformation buildInfo)
 {
     _pointerLayout = buildInfo.GetLayout("locale index table entry");
     _encryptionKey = buildInfo.LocaleKey;
     _symbols = buildInfo.LocaleSymbols;
     _localeArea = localeArea;
     _sizeAlign = (_encryptionKey != null) ? AES.BlockSize : 1;
     Load(values, segmenter, localeArea);
 }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:9,代码来源:ThirdGenLanguage.cs


示例14: FourthGenZoneSetTable

		public FourthGenZoneSetTable(FourthGenResourceGestalt gestalt, IReader reader, FileSegmentGroup metaArea,
			MetaAllocator allocator, EngineDescription buildInfo)
		{
			_gestalt = gestalt;
			_metaArea = metaArea;
			_allocator = allocator;
			_buildInfo = buildInfo;
			Load(reader);
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:9,代码来源:FourthGenZoneSetTable.cs


示例15: LoadSubmeshes

        private void LoadSubmeshes(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, BuildInformation buildInfo)
        {
            int count = (int)values.GetInteger("number of submeshes");
            uint address = values.GetInteger("submesh table address");
            var layout = buildInfo.GetLayout("model submesh");
            var entries = ReflexiveReader.ReadReflexive(reader, count, address, layout, metaArea);

            Submeshes = (from entry in entries
                         select new ThirdGenModelSubmesh(entry)).ToArray();
        }
开发者ID:iBotPeaches,项目名称:Assembly,代码行数:10,代码来源:ThirdGenModelSection.cs


示例16: LoadPermutations

        private void LoadPermutations(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, BuildInformation buildInfo)
        {
            int count = (int)values.GetInteger("number of permutations");
            uint address = values.GetInteger("permutation table address");
            var layout = buildInfo.GetLayout("model permutation");
            var entries = ReflexiveReader.ReadReflexive(count, address, reader, layout, metaArea);

            Permutations = (from entry in entries
                            select new ThirdGenModelPermutation(entry)).ToArray();
        }
开发者ID:Chrisco93,项目名称:Assembly,代码行数:10,代码来源:ThirdGenModelRegion.cs


示例17: LoadSegments

        private void LoadSegments(StructureValueCollection values, IReader reader, FileSegmentGroup metaArea, BuildInformation buildInfo, ThirdGenResourcePage[] pages)
        {
            int count = (int)values.GetInteger("number of raw segments");
            uint address = values.GetInteger("raw segment table address");
            var layout = buildInfo.GetLayout("raw segment table entry");
            var entries = ReflexiveReader.ReadReflexive(count, address, reader, layout, metaArea);

            Segments = (from entry in entries
                        select new ThirdGenResourceSegment(entry, pages)).ToArray();
        }
开发者ID:Chrisco93,项目名称:Assembly,代码行数:10,代码来源:ThirdGenResourceLayoutTable.cs


示例18: ThirdGenResourceManager

		/// <summary>
		///     Initializes a new instance of the <see cref="ThirdGenResourceManager" /> class.
		/// </summary>
		/// <param name="gestalt">The cache file's resource gestalt.</param>
		/// <param name="layoutTable">The cache file's resource layout table.</param>
		/// <param name="tags">The cache file's tag table.</param>
		/// <param name="metaArea">The cache file's meta area.</param>
		/// <param name="allocator">The cache file's tag data allocator.</param>
		/// <param name="buildInfo">The cache file's build information.</param>
		public ThirdGenResourceManager(ThirdGenResourceGestalt gestalt, ThirdGenResourceLayoutTable layoutTable, TagTable tags,
			FileSegmentGroup metaArea, MetaAllocator allocator, EngineDescription buildInfo)
		{
			_gestalt = gestalt;
			_layoutTable = layoutTable;
			_tags = tags;
			_metaArea = metaArea;
			_allocator = allocator;
			_buildInfo = buildInfo;
		}
开发者ID:t3hm00kz,项目名称:Assembly,代码行数:19,代码来源:ThirdGenResourceManager.cs


示例19: ThirdGenResourceGestalt

        public ThirdGenResourceGestalt(IReader reader, ITag zoneTag, FileSegmentGroup metaArea, MetaAllocator allocator,
			StringIDSource stringIDs, EngineDescription buildInfo)
        {
            _tag = zoneTag;
            _metaArea = metaArea;
            _allocator = allocator;
            _buildInfo = buildInfo;

            Load(reader, stringIDs);
        }
开发者ID:Cloms,项目名称:Assembly,代码行数:10,代码来源:ThirdGenResourceGestalt.cs


示例20: ThirdGenTagTable

        public ThirdGenTagTable(IReader reader, SegmentPointer indexHeaderLocation, FileSegmentGroup metaArea,
			MetaAllocator allocator, EngineDescription buildInfo)
        {
            _indexHeaderLocation = indexHeaderLocation;
            _metaArea = metaArea;
            _allocator = allocator;
            _buildInfo = buildInfo;

            Load(reader);
        }
开发者ID:ChadSki,项目名称:Assembly,代码行数:10,代码来源:ThirdGenTagTable.cs



注:本文中的Blamite.IO.FileSegmentGroup类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# Serialization.StructureValueCollection类代码示例发布时间:2022-05-24
下一篇:
C# Flexibility.StructureValueCollection类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap