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

ptisnovs at icedtea.classpath.org ptisnovs at icedtea.classpath.org
Mon Mar 24 10:05:39 UTC 2014


changeset 6c229eda647a in /hg/gfx-test
details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=6c229eda647a
author: Pavel Tisnovsky <ptisnovs at redhat.com>
date: Mon Mar 24 11:06:19 2014 +0100

	Ten new tests added into CAGOperationsOnTwoTouchingCircles.


diffstat:

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

diffs (272 lines):

diff -r 842891bb6f30 -r 6c229eda647a ChangeLog
--- a/ChangeLog	Fri Mar 21 11:21:55 2014 +0100
+++ b/ChangeLog	Mon Mar 24 11:06:19 2014 +0100
@@ -1,3 +1,8 @@
+2014-03-24  Pavel Tisnovsky  <ptisnovs at redhat.com>
+
+	* src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java:
+	Ten new tests added into CAGOperationsOnTwoTouchingCircles.
+
 2014-03-21  Pavel Tisnovsky  <ptisnovs at redhat.com>
 
 	* src/org/gfxtest/testsuites/BitBltMirrorImage.java:
diff -r 842891bb6f30 -r 6c229eda647a src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java
--- a/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java	Fri Mar 21 11:21:55 2014 +0100
+++ b/src/org/gfxtest/testsuites/CAGOperationsOnTwoTouchingCircles.java	Mon Mar 24 11:06:19 2014 +0100
@@ -1732,6 +1732,256 @@
         return TestResult.PASSED;
     }
 
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using inverse subtract operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testInverseSubtractTextureFillUsingHorizontalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingHorizontalStripesTexture(image, graphics2d);
+        // create area using inverse subtract operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingInverseSubtractOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using Intersect operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testIntersectTextureFillUsingHorizontalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingHorizontalStripesTexture(image, graphics2d);
+        // create area using Intersect operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingIntersectOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using Xor operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testXorTextureFillUsingHorizontalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingHorizontalStripesTexture(image, graphics2d);
+        // create area using Xor operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingXorOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using union operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testUnionTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d);
+        // create area using union operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using subtract operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testSubtractTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d);
+        // create area using subtract operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingSubtractOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using inverse subtract operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testInverseSubtractTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d);
+        // create area using inverse subtract operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingInverseSubtractOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using Intersect operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testIntersectTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d);
+        // create area using Intersect operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingIntersectOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using Xor operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testXorTextureFillUsingVerticalStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingVerticalStripesTexture(image, graphics2d);
+        // create area using Xor operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingXorOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using union operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testUnionTextureFillUsingHorizontalColorStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingHorizontalColorStripesTexture(image, graphics2d);
+        // create area using union operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
+    /**
+     * Checks the process of creating and rendering new geometric shape
+     * constructed from two touching circles using subtract operator. The shape is rendered
+     * using texture paint (fill).
+     * 
+     * @param image
+     *            image to which area is to be drawn
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testSubtractTextureFillUsingHorizontalColorStripesTexture(TestImage image, Graphics2D graphics2d)
+    {
+        // set stroke color
+        CommonRenderingStyles.setStrokeColor(graphics2d);
+        // set fill color
+        CommonRenderingStyles.setTextureFillUsingHorizontalColorStripesTexture(image, graphics2d);
+        // create area using subtract operator
+        Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingSubtractOperator(image);
+        // draw the area
+        graphics2d.fill(area);
+        // test result
+        return TestResult.PASSED;
+    }
+
         // create area using union operator
         Area area = CommonCAGOperations.createAreaFromTwoTouchingCirclesUsingUnionOperator(image);
         // draw the area


More information about the distro-pkg-dev mailing list