Package javax.media.jai

Examples of javax.media.jai.RenderedOp


        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURGIF8, "one-color.gif",
                                 new String[][]{{"v.width", "22"}},
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        assertEquals("width should be 22", 22, image.getWidth());
    }
View Full Code Here


        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURGIF8, "transparency.gif",
                                 new String[][]{{"v.width", "22"}},
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        assertEquals("width should be 22", 22, image.getWidth());
    }
View Full Code Here

        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURGIF8, "Big_counter.gif",
                                 new String[][]{{"v.width", "22"}},
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        assertEquals("width should be 22", 22, image.getWidth());
    }
View Full Code Here

        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURJPEG24, "transparency.gif",
                                 new String[][]{{"v.width", "22"}},
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        assertEquals("image should be 22 wide", 22, image.getWidth());
    }
View Full Code Here

        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURJPEG24, "asf-logo.svg",
                                 null,
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        image.getRendering();
    }
View Full Code Here

        InputStream stream = TestUtilities.
            doImageTranscodeTest(expectations,
                                 OutputImageRules.COLOURBMP24, "tcm.gif",
                                 null,
                                 true);
        RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
        image.getRendering();
    }
View Full Code Here

     *
     * @throws Exception
     */
    private void doTestInputImage(String rule, String file)
        throws Throwable {
        RenderedOp image = TestUtilities.transcodeToImage(
                expectations,
                rule, file,
                new String[][]{{"v.width", "22"}},
                true);

        assertEquals(22, image.getWidth());
    }
View Full Code Here

     *
     * @throws Exception
     */
    private void doTestInputImage(String rule, String file) throws Exception {
       
         RenderedOp image = TestUtilities.transcodeToImage(
             expectations,
             rule, file,
             new String[][]{{"v.width", "120"}},
             true);
     }
View Full Code Here

            reader = ImageIO.getImageReadersByFormatName("wbmp").next();
        }
        ParameterBlockJAI pblock = new ParameterBlockJAI("ImageRead");
        pblock.setParameter("Input", ImageIO.createImageInputStream(stream));
        pblock.setParameter("Reader", reader);
        RenderedOp image = JAI.create("ImageRead", pblock);

        int expectedWidth = width;
        int expectedHeight = (width > 512) ? width : 512;
        assertEquals("Incorrect image width", expectedWidth, image.getWidth());
        assertEquals("Incorrect image height", expectedHeight, image.getHeight());

        return image;
    }
View Full Code Here

                                         {"v.width", params[1][i]},
                                         {"v.p", getProtectedArea(
                                             Integer.parseInt(params[1][i]),
                                             params[0][i])}},
                                     true);
            RenderedOp image = JAI.create("ImageRead", ImageIO.createImageInputStream(stream));
            // Create the parameter block.
            PlanarImage dst = null;
            ParameterBlock pb = new ParameterBlock();
            pb.addSource(image);               // Specify the source image
            pb.add(null);                      // No ROI
View Full Code Here

TOP

Related Classes of javax.media.jai.RenderedOp

Copyright © 2018 www.massapicom. 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.