<AWT Dev> Review Request JDK:-8162959 [HiDPI] screenshot artifacts using AWT Robot
Prem Balakrishnan
prem.balakrishnan at oracle.com
Wed Nov 2 10:57:39 UTC 2016
Hi Alexander,
Please review updated patch.
http://cr.openjdk.java.net/~pkbalakr/8162959/webrev.01/
Added a new public API "Image createHiDPIScreenCapture(Rectangle screenRect)".
Returns an ordinary screenshot(BufferedImage) if the UI scale is 1.
Returns MultiResolutionImage for HiDPI display with two resolution variants,
1. Low Resolution/base image with user input width and height, I have used interpolation algorithm for scaling , adapted from JavaFX Robot (http://hg.openjdk.java.net/openjfx/9-dev/rt/rev/89a5de54b7dc),
2. High Resolution image with scaled width and height .
Regards,
Prem
From: Alexander Scherbatiy
Sent: Thursday, October 13, 2016 3:21 PM
To: Prem Balakrishnan; Sergey Bylokhov; awt-dev at openjdk.java.net
Subject: Re: Review Request JDK:-8162959 [HiDPI] screenshot artifacts using AWT Robot
On 06/10/16 15:28, Prem Balakrishnan wrote:
Hi,
Please review fix for JDK 9,
Bug: https://bugs.openjdk.java.net/browse/JDK-8162959
Webrev: HYPERLINK "http://cr.openjdk.java.net/%7Epkbalakr/8162959/webrev.00/"http://cr.openjdk.java.net/~pkbalakr/8162959/webrev.00/
I have adapted the same fix as used for JavaFX Robot
Bug: HYPERLINK "https://bugs.openjdk.java.net/browse/JDK-8162783"JDK-8162783.
Patch: http://hg.openjdk.java.net/openjfx/9-dev/rt/rev/89a5de54b7dc
New Public API " BufferedImage createScreenCapture(Rectangle screenRect, boolean isHiDPI)" is added,
Which will have a parameter to specify if HiDPI.
It is better to a add public method which returns MultiResolution image on HiDPI display and consists of two resoltion variants
- base image which has size requested by a user
- high-resolution image which creates an original screen capture
The proposed by your algorithm can be applied to the base image.
For more details see JDK-8020618 [macosx] java.awt.Robot makes blurry screen captures on Retina
Thanks,
Alexandr.
Regards,
Prem
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/awt-dev/attachments/20161102/06336b98/attachment-0001.html>
More information about the awt-dev
mailing list