Ejemplo n.º 1
0
        public CSMTextSettingsTag(SwfReader r)
        {
            TextId = r.GetUI16();
            UseFlashType = r.GetBits(2);
            GridFit = r.GetBits(3);
            r.GetBits(3); // reserved
            r.Align();

            Thickness = r.GetFixedNBits(32);
            Sharpness = r.GetFixedNBits(32);

            r.GetByte(); // reserved
        }
Ejemplo n.º 2
0
        public ZoneRecord(SwfReader r)
        {
            NumZoneData          = r.GetByte();
            AlignmentCoordinate1 = r.GetFixedNBits(16);
            Range1 = r.GetFixedNBits(16);
            AlignmentCoordinate2 = r.GetFixedNBits(16);
            Range2 = r.GetFixedNBits(16);

            r.GetBits(6); // reserved
            ZoneMaskX = r.GetBit();
            ZoneMaskY = r.GetBit();
            r.Align();
        }
Ejemplo n.º 3
0
        public ZoneRecord(SwfReader r)
        {
            NumZoneData = r.GetByte();
            AlignmentCoordinate1 = r.GetFixedNBits(16);
            Range1 = r.GetFixedNBits(16);
            AlignmentCoordinate2 = r.GetFixedNBits(16);
            Range2 = r.GetFixedNBits(16);

            r.GetBits(6); // reserved
            ZoneMaskX = r.GetBit();
            ZoneMaskY = r.GetBit();
            r.Align();
        }
Ejemplo n.º 4
0
        public CSMTextSettingsTag(SwfReader r)
        {
            TextId       = r.GetUI16();
            UseFlashType = r.GetBits(2);
            GridFit      = r.GetBits(3);
            r.GetBits(3);             // reserved
            r.Align();

            Thickness = r.GetFixedNBits(32);
            Sharpness = r.GetFixedNBits(32);

            r.GetByte();             // reserved
        }
Ejemplo n.º 5
0
        public Matrix(SwfReader r)
        {
            float sx = 1.0F;
            float sy = 1.0F;
            float r0 = 0.0F;
            float r1 = 0.0F;
            float tx = 0.0F;
            float ty = 0.0F;

            r.Align();
            bool hasScale = r.GetBit();

            if (hasScale)
            {
                uint scaleBits = r.GetBits(5);
                sx = r.GetFixedNBits(scaleBits);
                sy = r.GetFixedNBits(scaleBits);
            }
            bool hasRotate = r.GetBit();

            if (hasRotate)
            {
                uint nRotateBits = r.GetBits(5);
                r0 = r.GetFixedNBits(nRotateBits);
                r1 = r.GetFixedNBits(nRotateBits);
            }
            // always has translation
            uint nTranslateBits = r.GetBits(5);

            tx = r.GetSignedNBits(nTranslateBits);
            ty = r.GetSignedNBits(nTranslateBits);
            r.Align();

            this.ScaleX     = sx;
            this.Rotate0    = r0;
            this.Rotate1    = r1;
            this.ScaleY     = sy;
            this.TranslateX = tx;
            this.TranslateY = ty;
        }
Ejemplo n.º 6
0
        public Matrix(SwfReader r)
        {
            float sx = 1.0F;
            float sy = 1.0F;
            float r0 = 0.0F;
            float r1 = 0.0F;
            float tx = 0.0F;
            float ty = 0.0F;
            r.Align();
            bool hasScale = r.GetBit();
            if (hasScale)
            {
                uint scaleBits = r.GetBits(5);
                sx = r.GetFixedNBits(scaleBits);
                sy = r.GetFixedNBits(scaleBits);
            }
            bool hasRotate = r.GetBit();
            if (hasRotate)
            {
                uint nRotateBits = r.GetBits(5);
                r0 = r.GetFixedNBits(nRotateBits);
                r1 = r.GetFixedNBits(nRotateBits);
            }
            // always has translation
            uint nTranslateBits = r.GetBits(5);
            tx = r.GetSignedNBits(nTranslateBits);
            ty = r.GetSignedNBits(nTranslateBits);
            r.Align();

            this.ScaleX = sx;
            this.Rotate0 = r0;
            this.Rotate1 = r1;
            this.ScaleY = sy;
            this.TranslateX = tx;
            this.TranslateY = ty;
        }
Ejemplo n.º 7
0
 public PrimitiveFloat(SwfReader r)
 {
     FloatValue = r.GetFixedNBits(32);
 }
Ejemplo n.º 8
0
 public PrimitiveFloat(SwfReader r)
 {
     FloatValue = r.GetFixedNBits(32);
 }