The fixes for RT-25323 left conditions that cause exceptions for WebPane if the J2D pipeline is used with the test case attached to RT-23690.
The first is a locking issue for the J2D readbackbuffer which creates the following stack trace:
java.lang.IllegalStateException: Operation requires resource lock
at com.sun.prism.impl.ManagedResource.assertLocked(ManagedResource.java:228)
at com.sun.prism.impl.ManagedResource.getResource(ManagedResource.java:206)
at com.sun.prism.j2d.J2DTexture.getBufferedImage(J2DTexture.java:101)
at com.sun.prism.j2d.J2DRTTexture.createAWTGraphics2D(J2DRTTexture.java:104)
at com.sun.prism.j2d.J2DPrismGraphics.readBack(J2DPrismGraphics.java:1024)
Fixing that runs into a second problem with the following stack trace:
java.lang.AssertionError: Unexpected pixel format: BYTE_RGB
at com.sun.javafx.webkit.prism.RTImage$3.run(RTImage.java:131)
at com.sun.javafx.webkit.prism.PrismInvoker.runOnRenderThread(PrismInvoker.java:72)
at com.sun.javafx.webkit.prism.RTImage.getPixelBuffer(RTImage.java:123)
at com.sun.javafx.webkit.prism.RTImage.getImage(RTImage.java:36)
(This is caused by the underlying J2DRTTexture claiming it has a BYTE_RGB format when it actually has a supported BYTE_ARGB_PRE format.)
The first is a locking issue for the J2D readbackbuffer which creates the following stack trace:
java.lang.IllegalStateException: Operation requires resource lock
at com.sun.prism.impl.ManagedResource.assertLocked(ManagedResource.java:228)
at com.sun.prism.impl.ManagedResource.getResource(ManagedResource.java:206)
at com.sun.prism.j2d.J2DTexture.getBufferedImage(J2DTexture.java:101)
at com.sun.prism.j2d.J2DRTTexture.createAWTGraphics2D(J2DRTTexture.java:104)
at com.sun.prism.j2d.J2DPrismGraphics.readBack(J2DPrismGraphics.java:1024)
Fixing that runs into a second problem with the following stack trace:
java.lang.AssertionError: Unexpected pixel format: BYTE_RGB
at com.sun.javafx.webkit.prism.RTImage$3.run(RTImage.java:131)
at com.sun.javafx.webkit.prism.PrismInvoker.runOnRenderThread(PrismInvoker.java:72)
at com.sun.javafx.webkit.prism.RTImage.getPixelBuffer(RTImage.java:123)
at com.sun.javafx.webkit.prism.RTImage.getImage(RTImage.java:36)
(This is caused by the underlying J2DRTTexture claiming it has a BYTE_RGB format when it actually has a supported BYTE_ARGB_PRE format.)