summaryrefslogtreecommitdiff
path: root/terrain.h
diff options
context:
space:
mode:
authorJon Bergli Heier <snakebite@jvnv.net>2011-05-08 20:57:24 +0200
committerJon Bergli Heier <snakebite@jvnv.net>2011-05-08 20:57:24 +0200
commit4597c723c8dc1ab83fe23d7b330cd2ce974cba5d (patch)
treecdbeb00d3471e396dd343a06bb33d303c15a408a /terrain.h
parent3522593087c5e9037b56b5214099c466cbe9ee61 (diff)
Halve triangles/vertices per node, assume width and height is always 1.
Diffstat (limited to 'terrain.h')
-rw-r--r--terrain.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/terrain.h b/terrain.h
index 79a615e..b391f94 100644
--- a/terrain.h
+++ b/terrain.h
@@ -15,15 +15,14 @@ class Terrain {
struct Node {
Chunk *chunk;
- float x, y, width, height;
- float vertex_array[15];
+ float x, y;
+ float vertex_array[12];
- Node(Chunk *chunk, float x, float y, float width, float height);
+ Node(Chunk *chunk, float x, float y);
virtual ~Node();
float distance(float px, float pz);
void fill();
- void draw();
void draw_grid();
void draw_normal();
float get_height(float px, float py);