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


C# ByteReader.ReadF32方法代码示例

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


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

示例1: ReadV8

        protected override void ReadV8(ByteReader reader)
        {
            base.ReadV8(reader);

            DataFlags = reader.ReadU16();
            if (( DataFlags & 0x0001 ) == 0x0001) {
                // Pattern bits are valid
                if (( DataFlags & 0x0002 ) == 0x0002) {
                    float c = reader.ReadF32();
                    AmbientColor = new[] {c, c, c, 1.0f};
                } else {
                    AmbientColor = reader.ReadRGBA();
                }
                DiffuseColor = reader.ReadRGBA();
                if ( ( DataFlags & 0x0004 ) == 0x0004 ) {
                    float c = reader.ReadF32();
                    SpecularColor = new[] { c, c, c, 1.0f };
                } else {
                    SpecularColor = reader.ReadRGBA();
                }
                if ( ( DataFlags & 0x0008 ) == 0x0008 ) {
                    float c = reader.ReadF32();
                    EmissionColor = new[] { c, c, c, 1.0f };
                } else {
                    EmissionColor = reader.ReadRGBA();
                }
            } else {
                AmbientColor = reader.ReadRGBA();
                DiffuseColor = reader.ReadRGBA();
                SpecularColor = reader.ReadRGBA();
                EmissionColor = reader.ReadRGBA();
            }
            Shininess = reader.ReadF32();
        }
开发者ID:doug8679,项目名称:libJT,代码行数:34,代码来源:MaterialBaseAttribute.cs

示例2: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8(reader);
     VersionNumber = reader.ReadI16();
     if (VersionNumber == 1) {
         EnableFlag = reader.ReadU32();
         EnvMapTextureChannel = reader.ReadI32();
         EnvMapReflectivity = reader.ReadF32();
         BumpMapTextureChannel = reader.ReadI32();
         BumpinessFactor = reader.ReadF32();
         BumpMapNormalSpace = reader.ReadU32();
         PhongShadingFlag = reader.ReadU32();
         ReservedField = reader.ReadU32();
     }
 }
开发者ID:doug8679,项目名称:libJT,代码行数:15,代码来源:ShaderEffectsAttribute.cs

示例3: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8( reader );
     Position = reader.ReadHCoordF32();
     ConstantAttenuation = reader.ReadF32();
     LinearAttenuation = reader.ReadF32();
     QuadraticAttenuation = reader.ReadF32();
     SpreadAngle = reader.ReadF32();
     SpotDirection = reader.ReadDirF32();
     SpotIntensity = reader.ReadI32();
     VersionNumber = reader.ReadI16();
     if ( VersionNumber == 1 ) {
         CoordSystem = reader.ReadI32();
     }
 }
开发者ID:doug8679,项目名称:libJT,代码行数:15,代码来源:PointLightAttributeElement.cs

示例4: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8( reader );
     VersionNumber = reader.ReadI16();
     DataFlags = reader.ReadU8();
     PointSize = reader.ReadF32();
 }
开发者ID:doug8679,项目名称:libJT,代码行数:7,代码来源:PointStyleAttribute.cs

示例5: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8(reader);
     ObjectID = reader.ReadI32();
     AmbientColor = reader.ReadRGBA();
     DiffuseColor = reader.ReadRGBA();
     SpecularColor = reader.ReadRGBA();
     Brightness = reader.ReadF32();
 }
开发者ID:doug8679,项目名称:libJT,代码行数:9,代码来源:BaseLight.cs

示例6: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8( reader );
     ushort storedMask = reader.ReadU16();
     for ( int i = 0; i < 16; i++ ) {
         if ( ( storedMask & 0x8000 ) == 0x8000 ) {
             Transform[i] = reader.ReadF32();
         }
         storedMask <<= 1;
     }
 }
开发者ID:doug8679,项目名称:libJT,代码行数:11,代码来源:GeometricTransformAttribute.cs

示例7: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8(reader);
     DataFlags = reader.ReadU8();
     LineWidth = reader.ReadF32();
 }
开发者ID:doug8679,项目名称:libJT,代码行数:6,代码来源:LineStyleAttribute.cs

示例8: ReadV8

        protected override void ReadV8(ByteReader reader)
        {
            base.ReadV8(reader);
            PartitionFlags = reader.ReadI32();
            FileName = reader.ReadMbString();

            // Read the box either way, if the mask is set, this is a reserved field...do we ignore it?
            TransformedBoundingBox = reader.ReadBBoxF32();

            Area = reader.ReadF32();
            MinVertexCount = reader.ReadI32();
            MaxVertexCount = reader.ReadI32();
            MinNodeCount= reader.ReadI32();
            MaxNodeCount = reader.ReadI32();
            MinPolygonCount = reader.ReadI32();
            MaxPolygonCount = reader.ReadI32();

            if ( ( PartitionFlags & 0x00000001 ) != 0 ) {
                UnTransformedBoundingBox = reader.ReadBBoxF32();
            }
        }
开发者ID:doug8679,项目名称:libJT,代码行数:21,代码来源:PartitionNodeElement.cs

示例9: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8(reader);
     AreaFactor = reader.ReadF32();
 }
开发者ID:doug8679,项目名称:libJT,代码行数:5,代码来源:PointSetShapeNodeElement.cs

示例10: ReadV8

        protected override void ReadV8(ByteReader reader)
        {
            base.ReadV8(reader);

            // Read the transformed box
            TransformedBoundingBox = reader.ReadBBoxF32();
            // Read the untransformed box
            UntransformedBoundingBox = reader.ReadBBoxF32();
            Area = reader.ReadF32();
            MinVertexCount = reader.ReadI32();
            MaxVertexCount = reader.ReadI32();
            MinNodeCount= reader.ReadI32();
            MaxNodeCount = reader.ReadI32();
            MinPolygonCount = reader.ReadI32();
            MaxPolygonCount = reader.ReadI32();
            Size = reader.ReadI32();
            CompressionLevel = reader.ReadF32();
        }
开发者ID:doug8679,项目名称:libJT,代码行数:18,代码来源:BaseShapeNodeElement.cs

示例11: ReadV8

 protected override void ReadV8(ByteReader reader)
 {
     base.ReadV8( reader );
     Value = reader.ReadF32();
 }
开发者ID:doug8679,项目名称:libJT,代码行数:5,代码来源:FloatingPointPropertyAtom.cs


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