Working on the new refactor of primitive and shader

This commit is contained in:
2021-11-11 09:47:42 -08:00
parent ea5f68b479
commit 1e4ccc3e52
61 changed files with 635 additions and 440 deletions

View File

@ -0,0 +1,29 @@
// Copyright (c) 2021 Dominic Masters
//
// This software is released under the MIT License.
// https://opensource.org/licenses/MIT
#pragma once
#include "../../libs.h"
#include "../../util/math.h"
#include "primitive.h"
/** How many slices in each cylinder. */
#define SKYWALL_SLICE_COUNT 40
/** How many vertices per slice */
#define SKYWALL_VERTICES_PER_SLICE 2
/** How many indices per slice */
#define SKYWALL_INDICES_PER_SLICE 6
/** How many vertices in the cylinder, +1 to have the cylinder "wrap" */
#define SKYWALL_VERTICE_COUNT (SKYWALL_SLICE_COUNT+1)*SKYWALL_VERTICES_PER_SLICE
/** How many indices in the cylinder */
#define SKYWALL_INDICE_COUNT SKYWALL_INDICES_PER_SLICE*SKYWALL_SLICE_COUNT
/** How big the skywall cylinder is */
#define SKYWALL_SIZE 10
void skywallInit(primitive_t *primitive);