openMSX
Classes | Namespaces | Typedefs | Functions
gl_vec.hh File Reference
#include "Math.hh"
#include <algorithm>
#include <cassert>
#include <cmath>
#include <iostream>
Include dependency graph for gl_vec.hh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  gl::vecN< N, T >
 

Namespaces

 gl
 

Typedefs

using gl::vec2 = vecN< 2, float >
 
using gl::vec3 = vecN< 3, float >
 
using gl::vec4 = vecN< 4, float >
 
using gl::ivec2 = vecN< 2, int >
 
using gl::ivec3 = vecN< 3, int >
 
using gl::ivec4 = vecN< 4, int >
 

Functions

float gl::rsqrt (float x)
 
double gl::rsqrt (double x)
 
template<typename T >
gl::radians (T d)
 
template<typename T >
gl::degrees (T r)
 
template<int N, typename T >
bool gl::operator== (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
bool gl::operator!= (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::operator- (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, T > gl::operator+ (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::operator- (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::operator* (T x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::operator* (const vecN< N, T > &x, T y)
 
template<int N, typename T >
vecN< N, T > gl::operator* (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::recip (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, T > gl::operator/ (T x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::operator/ (const vecN< N, T > &x, T y)
 
template<int N, typename T >
vecN< N, T > gl::operator/ (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::min (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
gl::min_component (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, T > gl::max (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::clamp (const vecN< N, T > &x, const vecN< N, T > &minVal, const vecN< N, T > &maxVal)
 
template<int N, typename T >
vecN< N, T > gl::clamp (const vecN< N, T > &x, T minVal, T maxVal)
 
template<int N, typename T >
gl::sum (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, T > gl::sum_broadcast (const vecN< N, T > &x)
 
template<int N, typename T >
gl::dot (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
vecN< N, T > gl::dot_broadcast (const vecN< N, T > &x, const vecN< N, T > &y)
 
template<int N, typename T >
gl::length2 (const vecN< N, T > &x)
 
template<int N, typename T >
gl::length (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, T > gl::normalize (const vecN< N, T > &x)
 
template<typename T >
vecN< 3, T > gl::cross (const vecN< 3, T > &x, const vecN< 3, T > &y)
 
template<int N, typename T >
vecN< N, int > gl::round (const vecN< N, T > &x)
 
template<int N, typename T >
vecN< N, int > gl::trunc (const vecN< N, T > &x)
 
template<int N, typename T >
std::ostream & gl::operator<< (std::ostream &os, const vecN< N, T > &x)