/hg/gfx-test: Ten new tests added into CAGOperationsOnCircleAndR...

ptisnovs at icedtea.classpath.org ptisnovs at icedtea.classpath.org
Wed Nov 6 01:30:58 PST 2013


changeset 1519d3e53dea in /hg/gfx-test
details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=1519d3e53dea
author: Pavel Tisnovsky <ptisnovs at redhat.com>
date: Wed Nov 06 10:31:05 2013 +0100

	Ten new tests added into CAGOperationsOnCircleAndRectangle test suite.


diffstat:

 ChangeLog                                                         |    5 +
 src/org/gfxtest/testsuites/CAGOperationsOnCircleAndRectangle.java |  250 ++++++++++
 2 files changed, 255 insertions(+), 0 deletions(-)

diffs (272 lines):

diff -r 372bdbeb35f2 -r 1519d3e53dea ChangeLog
--- a/ChangeLog	Tue Nov 05 11:00:40 2013 +0100
+++ b/ChangeLog	Wed Nov 06 10:31:05 2013 +0100
@@ -1,3 +1,8 @@
+2013-11-06  Pavel Tisnovsky  <ptisnovs at redhat.com>
+
+	* src/org/gfxtest/testsuites/CAGOperationsOnCircleAndRectangle.java:
+	Ten new tests added into CAGOperationsOnCircleAndRectangle test suite.
+
 2013-11-05  Pavel Tisnovsky  <ptisnovs at redhat.com>
 
 	* src/org/gfxtest/testsuites/BitBltAffineQuadrantRotateTransformOp.java:
diff -r 372bdbeb35f2 -r 1519d3e53dea src/org/gfxtest/testsuites/CAGOperationsOnCircleAndRectangle.java
--- a/src/org/gfxtest/testsuites/CAGOperationsOnCircleAndRectangle.java	Tue Nov 05 11:00:40 2013 +0100
+++ b/src/org/gfxtest/testsuites/CAGOperationsOnCircleAndRectangle.java	Wed Nov 06 10:31:05 2013 +0100
@@ -2064,6 +2064,256 @@
     }
 
     /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using union operator. The shape is
+     * rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleUnionWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke width
+        CommonRenderingStyles.setStrokeThickWidth(graphics2d);
+        // create area using union operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingUnionOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using subtract operator. The shape
+     * is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleSubtractWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke width
+        CommonRenderingStyles.setStrokeThickWidth(graphics2d);
+        // create area using subtract operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingSubtractOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using inverse subtract operator.
+     * The shape is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleInverseSubtractWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke width
+        CommonRenderingStyles.setStrokeThickWidth(graphics2d);
+        // create area using inverse subtract operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingInverseSubtractOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using intersect operator. The shape
+     * is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleIntersectWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke width
+        CommonRenderingStyles.setStrokeThickWidth(graphics2d);
+        // create area using intersect operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingIntersectOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using XOR operator. The shape is
+     * rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleXorWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke width
+        CommonRenderingStyles.setStrokeThickWidth(graphics2d);
+        // create area using XOR operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingXorOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using union operator. The shape is
+     * rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleUnionExtraWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set extra wide stroke width
+        CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d);
+        // create area using union operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingUnionOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using subtract operator. The shape
+     * is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleSubtractExtraWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set extra wide stroke width
+        CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d);
+        // create area using subtract operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingSubtractOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using inverse subtract operator.
+     * The shape is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleInverseSubtractExtraWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set extra wide stroke width
+        CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d);
+        // create area using inverse subtract operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingInverseSubtractOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using intersect operator. The shape
+     * is rendered using wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleIntersectExtraWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set extra wide stroke width
+        CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d);
+        // create area using intersect operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingIntersectOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from circle and rectangle using XOR operator. The shape is
+     * rendered using extra wide stroke.
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testOverlappingCircleAndRectangleXorExtraWideStrokePaint(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set stroke extra width
+        CommonRenderingStyles.setStrokeExtraThickWidth(graphics2d);
+        // create area using XOR operator
+        Area area = CommonCAGOperations.createAreaFromOverlappingCircleAndRectangleUsingXorOperator(image);
+        // draw the area
+        graphics2d.draw(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
      * Entry point to the test suite.
      *
      * @param args not used in this case


More information about the distro-pkg-dev mailing list