31 lines
598 B
C++
31 lines
598 B
C++
#pragma once
|
|
|
|
#include <tuple>
|
|
#include <array>
|
|
#include "glm/gtc/type_aligned.hpp"
|
|
|
|
namespace zgl
|
|
{
|
|
|
|
template <typename T>
|
|
concept scalar = (
|
|
std::is_same_v<T, float> or
|
|
std::is_same_v<T, int> or
|
|
std::is_same_v<T, unsigned int> or
|
|
std::is_same_v<T, bool>
|
|
);
|
|
|
|
template<glm::length_t L, typename T>
|
|
using vec = glm::vec<L, T, glm::packed_highp>;
|
|
|
|
template<glm::length_t C, glm::length_t R, typename T>
|
|
using mat = glm::mat<C, R, T, glm::packed_highp>;
|
|
|
|
template<typename T, std::size_t Count>
|
|
using array = std::array<T, Count>;
|
|
|
|
template<typename... Ts>
|
|
using structure = std::tuple<Ts...>;
|
|
|
|
}
|