OGLplus (0.52.0) a C++ wrapper for OpenGL

oglplus::ObjectOps< tag::DirectState, tag::Sampler > Class Template Reference

Class wrapping sampler functions (with direct state access) More...

#include </home/chochlik/devel/oglplus/include/oglplus/sampler.hpp>

Inheritance diagram for oglplus::ObjectOps< tag::DirectState, tag::Sampler >:
Collaboration diagram for oglplus::ObjectOps< tag::DirectState, tag::Sampler >:

Public Types

typedef TextureUnitSelector Target
 Sampler bind targets.
 

Public Member Functions

Vector< GLfloat, 4 > BorderColor (TypeTag< GLfloat >) const
 Gets the texture border color. More...
 
void BorderColor (Vector< GLfloat, 4 > color)
 Sets the texture border color. More...
 
Vector< GLint, 4 > BorderColor (TypeTag< GLint >) const
 Gets the texture border color. More...
 
void BorderColor (Vector< GLint, 4 > color)
 Sets the texture border color. More...
 
Vector< GLuint, 4 > BorderColor (TypeTag< GLuint >) const
 Gets the texture border color. More...
 
void BorderColor (Vector< GLuint, 4 > color)
 Sets the texture border color. More...
 
TextureCompareMode CompareMode (void) const
 Gets the compare mode. More...
 
void CompareMode (TextureCompareMode mode)
 Sets the compare mode. More...
 
CompareFunction CompareFunc (void) const
 Gets the compare function. More...
 
void CompareFunc (CompareFunction func)
 Sets the compare function. More...
 
GLfloat LODBias (void) const
 Gets the LOD bias value. More...
 
void LODBias (GLfloat value)
 Sets the LOD bias value. More...
 
void Filter (TextureFilter filter) const
 Sets both the minification and magnification filter. More...
 
TextureMagFilter MagFilter (void) const
 Gets the magnification filter. More...
 
void MagFilter (TextureMagFilter filter)
 Sets the magnification filter. More...
 
TextureMinFilter MinFilter (void) const
 Gets the minification filter. More...
 
void MinFilter (TextureMinFilter filter)
 Sets the minification filter. More...
 
GLfloat MinLOD (void) const
 Gets minimal LOD value. More...
 
void MinLOD (GLfloat value)
 Sets minimal LOD value. More...
 
GLfloat MaxLOD (void) const
 Gets maximal LOD value. More...
 
void MaxLOD (GLfloat value)
 Sets maximal LOD value. More...
 
TextureWrap Wrap (TextureWrapCoord coord) const
 Gets the wrap parameter (TEXTURE_WRAP_*) More...
 
void Wrap (TextureWrapCoord coord, TextureWrap mode)
 Sets the wrap parameter (TEXTURE_WRAP_*) More...
 
TextureWrap WrapS (void) const
 Gets the wrap parameter for the S coordinate. More...
 
void WrapS (TextureWrap mode)
 Sets the wrap parameter for the S coordinate. More...
 
TextureWrap WrapT (void) const
 Gets the wrap parameter for the T coordinate. More...
 
void WrapT (TextureWrap mode)
 Sets the wrap parameter for the T coordinate. More...
 
TextureWrap WrapR (void) const
 Gets the wrap parameter for the R coordinate. More...
 
void WrapR (TextureWrap mode)
 Sets the wrap parameter for the R coordinate. More...
 
bool Seamless (void) const
 Gets the seamless cubemap setting. More...
 
void Seamless (bool enable)
 Sets the seamless cubemap setting. More...
 
void Bind (Target target) const
 Binds this sampler to the specified target (texture unit) More...
 

Static Public Member Functions

static void Bind (Target target, SamplerName sampler)
 Binds the specified sampler to the specified target (tex. unit) More...
 
static void Bind (GLuint first, const Sequence< SamplerName > &samplers)
 Sequentially bind samplers to texture units starting with first. More...
 
static SamplerName Binding (Target target)
 Returns the current Sampler bound to specified target (tex. unit) More...
 

Detailed Description

template<>
class oglplus::ObjectOps< tag::DirectState, tag::Sampler >

Class wrapping sampler functions (with direct state access)

Note
Do not use this class directly, use Sampler instead.

Member Function Documentation

static void oglplus::ObjBindingOps< tag::Sampler >::Bind ( Target  target,
SamplerName  sampler 
)
staticinherited

Binds the specified sampler to the specified target (tex. unit)

Related OpenGL symbols:
glBindSampler

References oglplus::GetGLName().

static void oglplus::ObjBindingOps< tag::Sampler >::Bind ( GLuint  first,
const Sequence< SamplerName > &  samplers 
)
staticinherited

Sequentially bind samplers to texture units starting with first.

Exceptions
Error
Related OpenGL symbols:
glBindSamplers Requires OpenGL 4.4 or the GL_ARB_multi_bind extension.

References oglplus::GetGLNames(), and oglplus::Sequence< ObjName >::size().

void oglplus::ObjCommonOps< tag::Sampler >::Bind ( Target  target) const
inherited

Binds this sampler to the specified target (texture unit)

Related OpenGL symbols:
glBindSampler
static SamplerName oglplus::ObjBindingOps< tag::Sampler >::Binding ( Target  target)
staticinherited

Returns the current Sampler bound to specified target (tex. unit)

Related OpenGL symbols:
glGetIntegerv
Vector<GLfloat, 4> oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( TypeTag< GLfloat >  ) const

Gets the texture border color.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_BORDER_COLOR
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( Vector< GLfloat, 4 >  color)

Sets the texture border color.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_BORDER_COLOR
Vector<GLint, 4> oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( TypeTag< GLint >  ) const

Gets the texture border color.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_BORDER_COLOR
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( Vector< GLint, 4 >  color)

Sets the texture border color.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_BORDER_COLOR
Vector<GLuint, 4> oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( TypeTag< GLuint >  ) const

Gets the texture border color.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_BORDER_COLOR
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::BorderColor ( Vector< GLuint, 4 >  color)

Sets the texture border color.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_BORDER_COLOR
CompareFunction oglplus::ObjectOps< tag::DirectState, tag::Sampler >::CompareFunc ( void  ) const

Gets the compare function.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_COMPARE_FUNC
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::CompareFunc ( CompareFunction  func)

Sets the compare function.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_COMPARE_FUNC
TextureCompareMode oglplus::ObjectOps< tag::DirectState, tag::Sampler >::CompareMode ( void  ) const

Gets the compare mode.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_COMPARE_MODE
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::CompareMode ( TextureCompareMode  mode)

Sets the compare mode.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_COMPARE_MODE
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::Filter ( TextureFilter  filter) const

Sets both the minification and magnification filter.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_MIN_FILTER GL_TEXTURE_MAG_FILTER
GLfloat oglplus::ObjectOps< tag::DirectState, tag::Sampler >::LODBias ( void  ) const

Gets the LOD bias value.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_LOD_BIAS
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::LODBias ( GLfloat  value)

Sets the LOD bias value.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_LOD_BIAS
TextureMagFilter oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MagFilter ( void  ) const

Gets the magnification filter.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_MAG_FILTER
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MagFilter ( TextureMagFilter  filter)

Sets the magnification filter.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_MAG_FILTER
GLfloat oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MaxLOD ( void  ) const

Gets maximal LOD value.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_MAX_LOD
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MaxLOD ( GLfloat  value)

Sets maximal LOD value.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_MAX_LOD
TextureMinFilter oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MinFilter ( void  ) const

Gets the minification filter.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_MIN_FILTER
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MinFilter ( TextureMinFilter  filter)

Sets the minification filter.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_MIN_FILTER
GLfloat oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MinLOD ( void  ) const

Gets minimal LOD value.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_MIN_LOD
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::MinLOD ( GLfloat  value)

Sets minimal LOD value.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_MIN_LOD
bool oglplus::ObjectOps< tag::DirectState, tag::Sampler >::Seamless ( void  ) const

Gets the seamless cubemap setting.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_CUBE_MAP_SEAMLESS
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::Seamless ( bool  enable)

Sets the seamless cubemap setting.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_CUBE_MAP_SEAMLESS
TextureWrap oglplus::ObjectOps< tag::DirectState, tag::Sampler >::Wrap ( TextureWrapCoord  coord) const

Gets the wrap parameter (TEXTURE_WRAP_*)

Related OpenGL symbols:
glGetSamplerParameter
void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::Wrap ( TextureWrapCoord  coord,
TextureWrap  mode 
)

Sets the wrap parameter (TEXTURE_WRAP_*)

Related OpenGL symbols:
glSamplerParameter
TextureWrap oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapR ( void  ) const

Gets the wrap parameter for the R coordinate.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_WRAP_R

References oglplus::R.

void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapR ( TextureWrap  mode)

Sets the wrap parameter for the R coordinate.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_WRAP_R

References oglplus::R.

TextureWrap oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapS ( void  ) const

Gets the wrap parameter for the S coordinate.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_WRAP_S

References oglplus::S.

void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapS ( TextureWrap  mode)

Sets the wrap parameter for the S coordinate.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_WRAP_S

References oglplus::S.

TextureWrap oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapT ( void  ) const

Gets the wrap parameter for the T coordinate.

Related OpenGL symbols:
glGetSamplerParameter GL_TEXTURE_WRAP_T

References oglplus::T.

void oglplus::ObjectOps< tag::DirectState, tag::Sampler >::WrapT ( TextureWrap  mode)

Sets the wrap parameter for the T coordinate.

Related OpenGL symbols:
glSamplerParameter GL_TEXTURE_WRAP_T

References oglplus::T.


The documentation for this class was generated from the following file:
  • /home/chochlik/devel/oglplus/include/oglplus/sampler.hpp

Copyright © 2010-2014 Matúš Chochlík, University of Žilina, Žilina, Slovakia.
<matus.chochlik -at- fri.uniza.sk>
<chochlik -at -gmail.com>
Documentation generated on Mon Sep 22 2014 by Doxygen (version 1.8.6).