50 lines
537 B
C++
50 lines
537 B
C++
#pragma once
|
|
|
|
#include <stdio.h>
|
|
|
|
template<class T> struct array {
|
|
T* data;
|
|
size_t len;
|
|
T& operator[](int i);
|
|
};
|
|
|
|
typedef unsigned int uint;
|
|
|
|
bool read_file(array<char>* out, const char* filepath);
|
|
|
|
struct vec4 {
|
|
float x;
|
|
float y;
|
|
float z;
|
|
float w;
|
|
};
|
|
|
|
struct vec3 {
|
|
float x;
|
|
float y;
|
|
float z;
|
|
};
|
|
|
|
struct vec2 {
|
|
float x;
|
|
float y;
|
|
};
|
|
|
|
struct vec4i {
|
|
int x;
|
|
int y;
|
|
int z;
|
|
int w;
|
|
};
|
|
|
|
struct vec3i {
|
|
int x;
|
|
int y;
|
|
int z;
|
|
};
|
|
|
|
struct vec2i {
|
|
int x;
|
|
int y;
|
|
};
|