Package Hexel.generation.terrainGenerator.heightMaps

Examples of Hexel.generation.terrainGenerator.heightMaps.HeightMap


        page.setColor(Color.white);
        page.fillRect(0, 0, this.getWidth(), this.getHeight());
        Vector2i tmp = new Vector2i();
        int s = 1;
        long t0 = System.currentTimeMillis();
        HeightMap hm = null;
        int cx = this.getWidth()/2;
        int cy = this.getHeight()/2;
        int rx = this.getWidth()/s/2;
        int ry = this.getHeight()/s/2;
        for (int x = -rx; x < rx; x++) {
          for (int y = -ry; y < ry; y++) {
            int hx = x+xshift;
            int hy = y+yshift;
            if (hm == null || !hm.containsPoint(hx, hy)){
              hm = tmg.getHeightMapAtXY(hx, hy, tmp, null);
            }
            int h = tmg.getHeight(hx, hy, tmp, hm);
            int wh = tmg.getWaterHeight(hx, hy, tmp);
            if (wh > h){
View Full Code Here

TOP

Related Classes of Hexel.generation.terrainGenerator.heightMaps.HeightMap

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.