void () { ImageComparator comparator = new ImageComparator(); /* * In fact, absolute accuracy is achieved by painting with enabled antialiasing, in which case alpha more precisely * shows sub-pixel offsets. However, in that case outlining the right/bottom rect edge would bring additional * complexity to calculating the outline x/y. This is likely an overkill. So, in this test the only scale factors * which allow to achieve pixel-perfect accuracy are counted (more precisely, the combination of factor and coordinates). * The test thus represents a defacto behaviour. */ // IDE-HiDPI for (double scale : new double[]{1, 1.25, /*1.5,*/ 1.75, 2, 2.25, 2.5, /*2.75,*/ 3}) { testRectOutline(comparator, scale, false, StrokeType.CENTERED); if (scale == 2.5) continue; testRectOutline(comparator, scale, false, StrokeType.INSIDE); } // JRE-HiDPI for (double scale : new double[]{1, 1.25, /*1.5,*/ 1.75, 2, 2.25, /*2.5,*/ 2.75, 3}) { testRectOutline(comparator, scale, true, StrokeType.CENTERED); testRectOutline(comparator, scale, true, StrokeType.INSIDE); } }