Rendering with raylib.

This commit is contained in:
2025-12-05 22:28:21 -05:00
parent 0984dec745
commit ffe092e1e1
7 changed files with 22 additions and 32 deletions

View File

@@ -12,8 +12,14 @@ void gen(void) {
for (int x = 0; x < VOL_WIDTH; x++) {
for (int y = 0; y < VOL_HEIGHT; y++) {
for (int z = 0; z < VOL_DEPTH; z++) {
if (rand() % 2 == 0) vol_set_vox(x, y, z, COL_WHT);
else vol_set_vox(x, y, z, COL_BLK);
int r = rand() % 4;
switch (r) {
case 0: vol_set_pt(x, y, z, COL_WHT); break;
case 1: vol_set_pt(x, y, z, COL_GRY); break;
case 2: vol_set_pt(x, y, z, COL_GRN); break;
case 3: vol_set_pt(x, y, z, COL_BLU); break;
default: vol_set_pt(x, y, z, COL_MAG);
}
}
}
}