On Tue, 3 Oct 2023 10:30:50 GMT, Alexander Zvegintsev <[email protected]> wrote:
> The current implementation of screen capture with ScreenCast has some > shortcomings in handling ui scale. > > This changeset includes: > > * sun.java2d.uiScale value is now taken into account > * screen data streams from ScreenCast are provided in native screen > resolution regardless of the scale set in the system. > Now we take that into account and resize the image accordingly. > * We are now trying all available `restore_token`, since it is is tied to the > display, but not to its resolution. > * Skips the gtk2 part of the ScreenCaptureGtkTest as it is not supported. > > Following tests are no longer failing on Wayland: > java/awt/Robot/HiDPIScreenCapture/HiDPIRobotScreenCaptureTest.java > java/awt/Robot/HiDPIScreenCapture/ScreenCaptureGtkTest.java > java/awt/Robot/HiDPIScreenCapture/ScreenCaptureTest.java > > Other testing also looks good, including manual testing with various scales > set in the system(including fractional scaling). Looks good. I assume performance is unchanged in the case when you can skip the scaling, which I expect is on all non-hidpi displays. ------------- Marked as reviewed by prr (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/16027#pullrequestreview-1662509426
