xcal
基于 C++23 的现代图形渲染引擎
|
N-dimensional mathematical vector implementation with template metaprogramming support 更多...
#include <assert.h>
#include <cmath>
#include <concepts>
#include <cstddef>
#include <type_traits>
#include "../utils/compiling.hpp"
#include "./declaration.hpp"
类 | |
struct | xcmath::VecInfo< _Tp > |
struct | xcmath::__batchHelper< T, len, lens > |
Metaclassfor constructing a vector from a pack of arguments 更多... | |
struct | xcmath::__batchHelper< T, len > |
Metaclass for constructing a vector from a pack of arguments 更多... | |
class | xcmath::vec< _Tp, _length > |
Vector class template 更多... | |
struct | xcmath::vec< _Tp, _length >::__subVecHelper< __Tp, __len, __lens > |
Metafunction for type transformation 更多... | |
struct | xcmath::vec< _Tp, _length >::__subVecHelper< size_t, __len, __lens... > |
struct | xcmath::vec< _Tp, _length >::__subVecHelper< size_t, __len > |
命名空间 | |
namespace | xcmath |
Compiler-specific type information handling for MSVC | |
概念 | |
concept | xcmath::Vec |
Type requirement concept for vector types | |
concept | xcmath::VecItem |
Concept for valid vector component types | |
宏定义 | |
#define | VEC_H |
#define | __VEC_OP_VEC_ON_EQ_LENGTH(op) |
Macro generating component-wise vector operations | |
#define | __VEC_OP_ITEM_ON_OP_ABLE(op) |
Macro generating vector-scalar operations | |
#define | __ITEM_OP_VEC_ON_OP_ENABLE(op) |
类型定义 | |
template<class T , size_t... lens> | |
using | xcmath::batch = __batchHelper< T, lens... >::Type |
Metafunction for constructing a vector from a pack of arguments | |
变量 | |
template<class Arg , class... Args> | |
constexpr size_t | xcmath::VecConstructPackSize |
Metafunction computing total size of vector constructor arguments | |
template<class Arg > | |
constexpr size_t | xcmath::VecConstructPackSize< Arg > |
Metafunction computing total size of vector constructor arguments | |
N-dimensional mathematical vector implementation with template metaprogramming support
Provides a type-safe, dimension-aware vector implementation supporting:
在文件 vec.hpp 中定义.
#define __ITEM_OP_VEC_ON_OP_ENABLE | ( | op | ) |
#define __VEC_OP_ITEM_ON_OP_ABLE | ( | op | ) |
Macro generating vector-scalar operations
op | Operator to apply (+, -, *, /, etc.) |
#define __VEC_OP_VEC_ON_EQ_LENGTH | ( | op | ) |
Macro generating component-wise vector operations
op | Operator to apply (+, -, *, /, etc.) |