Examples of DefineShape


Examples of flash.swf.tags.DefineShape

    {
    }

    public void fillstyle(Attributes attributes) throws SAXParseException
    {
        DefineShape defineShape = (DefineShape)stack.peek();
        boolean hasAlpha = (defineShape.code == stagDefineShape3);
        FillStyle fillstyle = new FillStyle();
        if (hasAttribute(attributes, "color"))
        {
            fillstyle.setType(FillStyle.FILL_SOLID);
View Full Code Here

Examples of flash.swf.tags.DefineShape

        if (hasAttribute(attributes, "dy"))
        {
            straightEdge.deltaY = parseInt(getAttribute(attributes, "dy"));
        }

        DefineShape defineShape = (DefineShape)stack.peek();
        defineShape.shapeWithStyle.shapeRecords.add(straightEdge);
    }
View Full Code Here

Examples of flash.swf.tags.DefineShape

    public void line()
    {}

    public void linestyle(Attributes attributes) throws SAXParseException
    {
        DefineShape defineShape = (DefineShape)stack.peek();
        LineStyle linestyle = new LineStyle();
        if (defineShape.code == stagDefineShape3)
        {
            linestyle.color = parseRGBA(getAttribute(attributes, "color"));
        }
View Full Code Here

Examples of flash.swf.tags.DefineShape

        if (fillstyles.size() != 0)
        {
            styleChange.stateNewStyles = true;
        }

        DefineShape defineShape = (DefineShape)stack.peek();
        defineShape.shapeWithStyle.shapeRecords.add(styleChange);
        fillstyles = defineShape.shapeWithStyle.fillstyles;
        linestyles = defineShape.shapeWithStyle.linestyles;
    }
View Full Code Here

Examples of flash.swf.tags.DefineShape

        builder.straight(0, 0);
        builder.correctRoundingErrors();
        sws.shapeRecords = builder.build().shapeRecords;

        // Wrap up into a SWF DefineShape Tag
        DefineShape defineShape = new DefineShape(Tag.stagDefineShape3);
        defineShape.bounds = new Rect(width * SwfConstants.TWIPS_PER_PIXEL, height * SwfConstants.TWIPS_PER_PIXEL);
        defineShape.shapeWithStyle = sws;

        return defineShape;
    }
View Full Code Here

Examples of flash.swf.tags.DefineShape

      oldPen = graphicContext.setPen(getShapeStart(shape));
    }

    DefineShapeBuilder builder = new DefineShapeBuilder(shape, graphicContext, draw, fill);

    DefineShape ds3 = (DefineShape)builder.build();
    defineTags.defineShape3(ds3);

    Matrix matrix;

    if (isGradient)
View Full Code Here

Examples of flash.swf.tags.DefineShape

        int width = losslessImage.getWidth();
        int height = losslessImage.getHeight();
      DefineBitsLossless defineBits = DefineBitsLosslessBuilder.build(losslessImage.getPixels(), width, height);
      defineTags.defineBitsLossless2(defineBits);

      DefineShape ds3 = ImageShapeBuilder.buildImage(defineBits, defineBits.width, defineBits.height);
      defineTags.defineShape3(ds3);
      applyBounds(ds3.bounds.xMin, ds3.bounds.yMin, ds3.bounds.xMax, ds3.bounds.yMax);

      PlaceObject po2 = new PlaceObject(Tag.stagPlaceObject2);
      po2.setMatrix(MatrixBuilder.build(at));
View Full Code Here

Examples of flash.swf.tags.DefineShape

            int width = losslessImage.getWidth();
            int height = losslessImage.getHeight();
            DefineBitsLossless defineBits = DefineBitsLosslessBuilder.build(losslessImage.getPixels(), width, height);
      defineTags.defineBitsLossless2(defineBits);

      DefineShape ds3 = ImageShapeBuilder.buildImage(defineBits, defineBits.width, defineBits.height);
      defineTags.defineShape3(ds3);
            applyBounds(ds3.bounds.xMin, ds3.bounds.yMin, ds3.bounds.xMax, ds3.bounds.yMax);

      PlaceObject po2 = new PlaceObject(ds3, depth++);
            po2.setMatrix(MatrixBuilder.build(graphicContext.getTransform()));
View Full Code Here

Examples of flash.swf.tags.DefineShape

                JPEGImage image = new JPEGImage(inputStream, length);
                DefineBits defineBits = new DefineBits(Tag.stagDefineBitsJPEG2);
                defineBits.data = image.getData();
        defineTags.defineBitsJPEG2(defineBits);

        DefineShape ds3 = ImageShapeBuilder.buildImage(defineBits, width, height);
        defineTags.defineShape3(ds3);
        applyBounds(ds3.bounds.xMin, ds3.bounds.yMin, ds3.bounds.xMax, ds3.bounds.yMax);

                PlaceObject po2 = new PlaceObject(ds3, depth++);
                po2.setMatrix(MatrixBuilder.build(graphicContext.getTransform()));
View Full Code Here

Examples of flash.swf.tags.DefineShape

            ShapeWithStyle sws = new ShapeWithStyle();
            sws.shapeRecords = shape.shapeRecords;
            sws.linestyles = new ArrayList();
            sws.fillstyles = new ArrayList();
            sws.fillstyles.add(new FillStyle(SwfUtils.colorToInt(0, 0, 200, 255)));
            DefineShape tag = new DefineShape(Tag.stagDefineShape3);
            tag.bounds = new Rect(250 * 20, 250 * 20);
            tag.shapeWithStyle = sws;

            //Create a SWF Movie shell
            Movie m = getMovie(1);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.