当前位置: 首页>>代码示例>>C#>>正文


C# Stream.ReadContent方法代码示例

本文整理汇总了C#中System.IO.Stream.ReadContent方法的典型用法代码示例。如果您正苦于以下问题:C# Stream.ReadContent方法的具体用法?C# Stream.ReadContent怎么用?C# Stream.ReadContent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在System.IO.Stream的用法示例。


在下文中一共展示了Stream.ReadContent方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: ReadFromStream

 public void ReadFromStream(Stream stream)
 {
     Header = stream.ReadContent<YkdHeader>();
     Background = stream.ReadContent<YkdBlock>();
     Offsets = stream.ReadContent<YkdOffsets>();
     Blocks = new YkdBlock[Offsets.Count];
     for (int i = 0; i < Blocks.Length; i++)
     {
         stream.SetPosition(Offsets[i]);
         Blocks[i] = stream.ReadContent<YkdBlock>();
     }
     Resources = stream.ReadContent<YkdResources>();
 }
开发者ID:kidaa,项目名称:Pulse,代码行数:13,代码来源:YkdFile.cs

示例2: ReadFromStream

 public void ReadFromStream(Stream stream)
 {
     BinaryReader br = new BinaryReader(stream);
     SamplesPerBlock = br.ReadInt16();
     CoefficientsCount = br.ReadInt16();
     Coefficients = stream.ReadContent<AdPcmCoefficientSet>(CoefficientsCount);
 }
开发者ID:kidaa,项目名称:Pulse,代码行数:7,代码来源:AdPcmWaveExtraData.cs

示例3: ReadFromStream

 public void ReadFromStream(Stream stream)
 {
     BinaryReader br = new BinaryReader(stream);
     Count = br.ReadInt32();
     Unknown1 = br.ReadInt32();
     Unknown2 = br.ReadInt32();
     Unknown3 = br.ReadInt32();
     Tails = stream.ReadContent<YkdBlockOptionalTail>(Count);
 }
开发者ID:truongan012,项目名称:Pulse,代码行数:9,代码来源:YkdBlockOptionalTails.cs

示例4: ReadFromStream

        public void ReadFromStream(Stream stream)
        {
            BinaryReader br = new BinaryReader(stream);

            Unknown1 = br.ReadInt32();
            Unknown2 = br.ReadInt32();
            int count = br.ReadInt32();
            Unknown3 = br.ReadInt32();

            int[] offsets = new int[count];
            for (int i = 0; i < count; i++)
                offsets[i] = br.ReadInt32();

            int alignment = ((4 - (count % 4)) % 4);
            for (int i = 0; i < alignment; i++)
                br.Check(r => r.ReadInt32(), 0);

            Frames = new YkdFrame[count];
            for (int i = 0; i < count; i++)
            {
                stream.SetPosition(offsets[i]);
                Frames[i] = stream.ReadContent<YkdFrame>();
            }
        }
开发者ID:kidaa,项目名称:Pulse,代码行数:24,代码来源:YkdFrames.cs

示例5: ReadFromStream

 public virtual void ReadFromStream(Stream stream)
 {
     SectionHeader = stream.ReadContent<SectionHeader>();
 }
开发者ID:kidaa,项目名称:Pulse,代码行数:4,代码来源:SectionBase.cs

示例6: ReadFromStream

 public void ReadFromStream(Stream input)
 {
     Header = input.ReadContent<GtexHeader>();
     MipMapData = input.ReadContent<GtexMipMapLocation>(Header.LayerCount);
 }
开发者ID:akimoto-akira,项目名称:Pulse,代码行数:5,代码来源:GtexData.cs

示例7: ReadFromStream

 public override void ReadFromStream(Stream input)
 {
     base.ReadFromStream(input);
     TextureHeader = input.ReadContent<TextureHeader>();
     Gtex = input.ReadContent<GtexData>();
 }
开发者ID:kidaa,项目名称:Pulse,代码行数:6,代码来源:TextureSection.cs


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