ReadData() public method

Reads the data.
public ReadData ( BufferedBinaryReader binaryReader ) : void
binaryReader SwfDotNet.IO.Utils.BufferedBinaryReader Binary reader.
return void
Example #1
0
        /// <summary>
        /// Reads the data.
        /// </summary>
        /// <param name="binaryReader">Binary reader.</param>
        public void ReadData(BufferedBinaryReader binaryReader)
        {
            uint count = 0;

            byte lineStyleCount = binaryReader.ReadByte();

            count = lineStyleCount;

            ushort lineStyleCountExtended = 0;

            if (lineStyleCount == 0xFF)
            {
                lineStyleCountExtended = binaryReader.ReadUInt16();
                count = lineStyleCountExtended;
            }

            if (count > 0)
            {
                for (int i = 0; i < count; i++)
                {
                    MorphLineStyle morphLineStyle = new MorphLineStyle();
                    morphLineStyle.ReadData(binaryReader);
                    this.Add(morphLineStyle);
                }
            }
        }
Example #2
0
        /// <summary>
        /// Reads the data.
        /// </summary>
        /// <param name="binaryReader">Binary reader.</param>
        public void ReadData(BufferedBinaryReader binaryReader)
        {
            uint count = 0;

            byte lineStyleCount = binaryReader.ReadByte();
            count = lineStyleCount;

            ushort lineStyleCountExtended = 0;
            if (lineStyleCount == 0xFF)
            {
                lineStyleCountExtended = binaryReader.ReadUInt16();
                count = lineStyleCountExtended;
            }

            if (count > 0)
            {
                for (int i = 0; i < count; i++)
                {
                    MorphLineStyle morphLineStyle = new MorphLineStyle();
                    morphLineStyle.ReadData(binaryReader);
                    this.Add(morphLineStyle);
                }
            }
        }