On 10.02.2015 5:26, DRC wrote:
You're missing my point. ARGB_PRE images are faster with OpenGL but
not as fast with other blitters, so currently in order to achieve
optimal performance, my program has to somehow predict when OpenGL
blitting will be used and use an ARGB_PRE image only in those cases.
Do you mean that in some other pipelines like d3d,gdi,xrender an image
returned from CreateCompatibleImage is working not as fast as some
another image? it can be a bug. I suppose
createCompatibleImag(x,y,Transparency.TRANSLUCENT) should be faster in
any case on all pipelines, since it takes care of best image format.(and
it should return argb_pre in case of ogl)
(3) Is Java 9 supposed to make this faster in any way? Your other
message
(http://mail.openjdk.java.net/pipermail/2d-dev/2014-October/004870.html)
indicated that there was some change introduced in the Java 9
pre-releases that might affect this, but after testing the pre-release
builds, I can't make them perform any differently than Java 7 or 8.
Same fixes were pushed to 8u40. All of them related to the
BufferedImage2surface scaleblit.
Example report
http://cr.openjdk.java.net/~serb/8059942/ogl_nvidia_win_fix14/results_ogl.txt
So when would that code path be activated?
You can run this test on jdk 8u31 and 8u40 to see a difference:
http://cr.openjdk.java.net/~serb/8029253/webrev.04/test/java/awt/image/DrawImage/UnmanagedDrawImagePerformance.java.html
And the test from this bug report:
https://bugs.openjdk.java.net/browse/JDK-8017247
It was measured. Please refer to my original post describing how to
reproduce my results:
http://mail.openjdk.java.net/pipermail/macosx-port-dev/2014-August/006700.html
On the benchmark that simulates my specific workload (ImageDrawTest),
the performance is always considerably slower under Java 1.7 and later
on Mac when compared to Java 1.6.
Can you share standalone jar file of this workload?
Using pre-computed ARGB images helps, but in no case can I make the
OpenGL blitter achieve the same performance as the Quartz blitter used
to. In other words, from my point of view, the performance of Java
1.7 and later have regressed. I am not the only one reporting this
issue.
In general it will be good to reduce the number of OGLSwToSurfaceBlit blits.
--
Best regards, Sergey.