/hg/gfx-test: Two new kernels and ROPs based on them added, four...

ptisnovs at icedtea.classpath.org ptisnovs at icedtea.classpath.org
Fri Aug 16 01:36:15 PDT 2013


changeset 01be1bd23272 in /hg/gfx-test
details: http://icedtea.classpath.org/hg/gfx-test?cmd=changeset;node=01be1bd23272
author: Pavel Tisnovsky <ptisnovs at redhat.com>
date: Fri Aug 16 10:39:51 2013 +0200

	Two new kernels and ROPs based on them added, four new tests added
	into BitBltConvolveOp test suite too.


diffstat:

 ChangeLog                                        |   6 +
 src/org/gfxtest/testsuites/BitBltConvolveOp.java |  82 ++++++++++++++++++++++-
 2 files changed, 82 insertions(+), 6 deletions(-)

diffs (139 lines):

diff -r 4477ada87429 -r 01be1bd23272 ChangeLog
--- a/ChangeLog	Thu Aug 15 10:20:35 2013 +0200
+++ b/ChangeLog	Fri Aug 16 10:39:51 2013 +0200
@@ -1,3 +1,9 @@
+2013-08-16  Pavel Tisnovsky  <ptisnovs at redhat.com>
+
+	* src/org/gfxtest/testsuites/BitBltConvolveOp.java:
+	Two new kernels and ROPs based on them added, four new tests added
+	into BitBltConvolveOp test suite too.
+
 2013-08-15  Pavel Tisnovsky  <ptisnovs at redhat.com>
 
 	* src/org/gfxtest/testsuites/BitBltUsingBgColor.java:
diff -r 4477ada87429 -r 01be1bd23272 src/org/gfxtest/testsuites/BitBltConvolveOp.java
--- a/src/org/gfxtest/testsuites/BitBltConvolveOp.java	Thu Aug 15 10:20:35 2013 +0200
+++ b/src/org/gfxtest/testsuites/BitBltConvolveOp.java	Fri Aug 16 10:39:51 2013 +0200
@@ -76,7 +76,7 @@
                     0.0f, 0.0f, 0.0f,
                     0.0f, 1.0f, 0.0f,
                     0.0f, 0.0f, 0.0f
-    });
+                    });
 
     private static final Kernel NoOpKernel5x5 = new Kernel(5, 5, new float[] {
                     0.0f, 0.0f, 0.0f, 0.0f, 0.0f,
@@ -106,17 +106,28 @@
                     });
 
     private static final Kernel SobelOperatorGx = new Kernel(3, 3, new float[] {
-                    1f, 0f, -1f,
-                    2f, 0f, -2f,
-                    1f, 0f, -1f
+                     1f, 0f, -1f,
+                     2f, 0f, -2f,
+                     1f, 0f, -1f
                     });
 
     private static final Kernel SobelOperatorGy = new Kernel(3, 3, new float[] {
-                    1f, 2f, 1f,
-                    0f, 0f, 0f,
+                     1f,  2f,  1f,
+                     0f,  0f,  0f,
                     -1f, -2f, -1f
                     });
 
+    private static final Kernel LaplaceOperator = new Kernel(3, 3, new float[] {
+                     0f, 1f, 0f,
+                     1f,-4f, 1f,
+                     0f, 1f, 0f
+                    });
+
+    private static final Kernel LaplaceOperatorDiag = new Kernel(3, 3, new float[] {
+                    1f, 1f, 1f,
+                    1f,-8f, 1f,
+                    1f, 1f, 1f
+                   });
 
     private static final ConvolveOp noopKernel1x1ROP = new ConvolveOp(NoOpKernel1x1);
     private static final ConvolveOp noopKernel3x3ROP = new ConvolveOp(NoOpKernel3x3);
@@ -129,6 +140,9 @@
     private static final ConvolveOp sobelOperatorGxROP = new ConvolveOp(SobelOperatorGx);
     private static final ConvolveOp sobelOperatorGyROP = new ConvolveOp(SobelOperatorGy);
 
+    private static final ConvolveOp laplaceOperatorROP = new ConvolveOp(LaplaceOperator);
+    private static final ConvolveOp laplaceOperatorDiagROP = new ConvolveOp(LaplaceOperatorDiag);
+
     /**
      * Test basic BitBlt operation for empty buffered image with type TYPE_3BYTE_BGR.
      *
@@ -242,6 +256,34 @@
     }
 
     /**
+     * Test basic BitBlt operation for empty buffered image with type TYPE_3BYTE_BGR.
+     *
+     * @param image
+     *            image used as a destination for BitBlt-type operations
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testBitBltEmptyBufferedImageType3ByteBGRbackgroundLaplaceOperatorROP(TestImage image, Graphics2D graphics2d)
+    {
+        return doBitBltEmptyBufferedImageType3ByteRGB(image, graphics2d, laplaceOperatorROP);
+    }
+
+    /**
+     * Test basic BitBlt operation for empty buffered image with type TYPE_3BYTE_BGR.
+     *
+     * @param image
+     *            image used as a destination for BitBlt-type operations
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testBitBltEmptyBufferedImageType3ByteBGRbackgroundLaplaceOperatorDiagROP(TestImage image, Graphics2D graphics2d)
+    {
+        return doBitBltEmptyBufferedImageType3ByteRGB(image, graphics2d, laplaceOperatorDiagROP);
+    }
+
+    /**
      * Test basic BitBlt operation for empty buffered image with type TYPE_4BYTE_ABGR.
      *
      * @param image
@@ -578,6 +620,34 @@
     }
 
     /**
+     * Test basic BitBlt operation for checker buffered image with type TYPE_3BYTE_BGR.
+     *
+     * @param image
+     *            image used as a destination for BitBlt-type operations
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testBitBltCheckerBufferedImageType3ByteBGRbackgroundLaplaceOperatorROP(TestImage image, Graphics2D graphics2d)
+    {
+        return doBitBltCheckerBufferedImageType3ByteRGB(image, graphics2d, laplaceOperatorROP);
+    }
+
+    /**
+     * Test basic BitBlt operation for checker buffered image with type TYPE_3BYTE_BGR.
+     *
+     * @param image
+     *            image used as a destination for BitBlt-type operations
+     * @param graphics2d
+     *            graphics canvas
+     * @return test result status - PASSED, FAILED or ERROR
+     */
+    public TestResult testBitBltCheckerBufferedImageType3ByteBGRbackgroundLaplaceOperatorDiagROP(TestImage image, Graphics2D graphics2d)
+    {
+        return doBitBltCheckerBufferedImageType3ByteRGB(image, graphics2d, laplaceOperatorDiagROP);
+    }
+
+    /**
      * Test basic BitBlt operation for diagonal checker buffered image with type TYPE_3BYTE_BGR.
      *
      * @param image



More information about the distro-pkg-dev mailing list