Changeset 8140 in josm


Ignore:
Timestamp:
2015-03-15T16:05:26+01:00 (10 years ago)
Author:
bastiK
Message:

mappaint: turn off anti-aliasing for area drawing (small performance improvement)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java

    r8113 r8140  
    321321
    322322    private boolean leftHandTraffic;
     323    private Object antialiasing;
    323324
    324325    /**
     
    439440
    440441        if (!isOutlineOnly) {
     442            g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF);
    441443            if (fillImage == null) {
    442444                if (isInactiveMode) {
     
    456458                g.setPaintMode();
    457459            }
     460            g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, antialiasing);
    458461        }
    459462
     
    13961399        orderFont = new Font(Main.pref.get("mappaint.font", "Droid Sans"), Font.PLAIN, Main.pref.getInteger("mappaint.fontsize", 8));
    13971400
    1398         g.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
    1399                 Main.pref.getBoolean("mappaint.use-antialiasing", true) ?
    1400                         RenderingHints.VALUE_ANTIALIAS_ON : RenderingHints.VALUE_ANTIALIAS_OFF);
     1401        antialiasing = Main.pref.getBoolean("mappaint.use-antialiasing", true) ?
     1402                        RenderingHints.VALUE_ANTIALIAS_ON : RenderingHints.VALUE_ANTIALIAS_OFF;
     1403        g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, antialiasing);
    14011404
    14021405        highlightLineWidth = Main.pref.getInteger("mappaint.highlight.width", 4);
     
    16451648                timeStart = System.currentTimeMillis();
    16461649                System.err.print("BENCHMARK: rendering ");
    1647                 Main.debug(null);
    16481650            }
    16491651
Note: See TracChangeset for help on using the changeset viewer.