fennec
Loading...
Searching...
No Matches
fennec::swizzle< VectorT, DataT, ScalarT, IndicesV >

Structure for Handling Vector Swizzling. More...

#include <swizzle.h>

Inherits fennec::detail::swizzle_storage< DataT, ScalarT, IndicesV >.

Detailed Description

template<typename VectorT, typename DataT, typename ScalarT, size_t... IndicesV>
struct fennec::swizzle< VectorT, DataT, ScalarT, IndicesV >
Template Parameters
VectorTVector Type
DataTBase Data Type
ScalarTScalar Base Type
IndicesVSwizzle Indices

Public Types

using scalar_t = ScalarT
 alias for the scalar type
 

Public Member Functions

constexpr VectorT decay () const
 Decay the Swizzle into a Vector.
 
constexpr operator VectorT () const
 Vector Cast Operator.
 

Static Public Attributes

aliases for the size
static constexpr size_t dimension = sizeof...(IndicesV)
 dimension of the swizzle
 
static constexpr size_t num_components = sizeof...(IndicesV)
 number of components
 
static constexpr size_t size = sizeof...(IndicesV)
 size of the swizzle
 
static constexpr size_t N = sizeof...(IndicesV)
 size of the swizzle
 

Member Function Documentation

◆ decay()

template<typename VectorT , typename DataT , typename ScalarT , size_t... IndicesV>
constexpr VectorT fennec::swizzle< VectorT, DataT, ScalarT, IndicesV >::decay ( ) const
inlineconstexpr
Returns
The Value of the Swizzle as a Vector

◆ operator VectorT()

template<typename VectorT , typename DataT , typename ScalarT , size_t... IndicesV>
constexpr fennec::swizzle< VectorT, DataT, ScalarT, IndicesV >::operator VectorT ( ) const
inlineexplicitconstexpr
Returns
The Value of the Swizzle as a Vector

The documentation for this struct was generated from the following file: