mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-13 15:01:49 +00:00
Chunks render moved to ChunksLoader
This commit is contained in:
parent
15bed4169e
commit
f569378b88
12 changed files with 127 additions and 43 deletions
|
|
@ -1,6 +1,8 @@
|
|||
#ifndef VOXELS_CHUNK_H_
|
||||
#define VOXELS_CHUNK_H_
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#define CHUNK_W 16
|
||||
#define CHUNK_H 256
|
||||
#define CHUNK_D 16
|
||||
|
|
@ -9,6 +11,11 @@
|
|||
class voxel;
|
||||
class Lightmap;
|
||||
|
||||
struct RenderData {
|
||||
float* vertices;
|
||||
size_t size;
|
||||
};
|
||||
|
||||
class Chunk {
|
||||
public:
|
||||
int x,y,z;
|
||||
|
|
@ -19,6 +26,8 @@ public:
|
|||
bool loaded = false;
|
||||
int surrounding = 0;
|
||||
int references = 1;
|
||||
RenderData renderData;
|
||||
|
||||
Chunk(int x, int y, int z);
|
||||
~Chunk();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue