A parent texture class containing template data and functionality.
Definition Texture.h:71
__host__ __device__ const SizeType & Size() const
Definition Texture.h:82
static constexpr std::size_t DIMENSIONALITY
Definition Texture.h:73
Texture(const Texture &)=default
__host__ __device__ const VectorType & Spacing() const
Get the spacing of the texture's values in world coordinates as (X, Y, Z)
Definition Texture.h:84
Vec< floatType, dimensionality > VectorType
Definition Texture.h:77
__host__ __device__ const VectorType & CentrePosition() const
Get the position of the centre of the texture in world coordinates as (X, Y, Z)
Definition Texture.h:86
__host__ __device__ Linear< VectorType > MappingWorldToTexCoord() const
Definition Texture.h:107
Texture & operator=(const Texture &)=default
__host__ __device__ VectorType SizeWorld() const
Definition Texture.h:91
Texture(SizeType _size, VectorType _spacing, VectorType _centrePosition={})
Definition Texture.h:116
Texture(Texture &&) noexcept=default
__host__ __device__ bool In(const SizeType &index) const
Definition Texture.h:99
__host__ static __device__ constexpr Vec Full(const T &value)
Construct a Vec, copying the given value into every element.
Definition Vec.h:64
Vec< TextureAddressMode, DIMENSIONALITY > StringsToAddressModes(const std::array< std::string_view, DIMENSIONALITY > &strings)
Definition Texture.h:44
@ ZERO
Sampling locations outside texture coordinate range will be read as 0.