21#include <Inventor/SbLinear.h> 
   25#define VIEW2D_BICUBIC_FILTER_TEX_SIZE 256 
   29template <
typename T> 
class LUTData;
 
   40  virtual const char* 
name() = 0;
 
 
View2DTextureFilter
Filter mode.
 
#define SOVIEW2D_API
File to resolve system dependencies in View2D library.
 
A small wrapper class for the LUT data.
 
base class for hardware shaders that can be used on a View2DTexture
 
virtual void unbind()=0
deactivates the shader
 
virtual float getLutHeightScaleFactor()
 
View2DLut * _lut
pointer to the LUT data
 
virtual void bindLutTexture()
bind the lut texture to the current texture unit
 
virtual SbVec2s getLutTextureSize()
 
virtual void bindFilterKernelTexture()
bind the filter kernel texture
 
int _lastLutSize
last size of lut
 
virtual const char * name()=0
returns the name of the shader
 
void invalidateLut()
invalidate the lut
 
virtual void getRequiredTextureLayout(View2DTexture *texture, GLuint &format, GLuint &internalFormat, GLuint &transferDataType)
returns the required texture layout that a GL texture must use, as GL_format enums and datatypes
 
View2DLut * getLut()
gets the lut
 
virtual void setLut(View2DLut *newLut)
sets the lut currently used
 
static void applyTextureFilter(View2DTextureFilter filter)
set the correct texture filtering on the currently bound texture
 
virtual void bind(View2DTexture *texture, int tw, int th)=0
binds/activates the shader, tw and th give the "poweroftwo" size of current subtexture that is render...
 
ml::LUTDataId _lastLutChangeID
id of last lut
 
abstract base class for shaders that use a 2D texture for LUT lookup
 
void createLutTexture()
creates a 2D texture from the shader's LUT
 
void createFilterKernelTexture()
create 1d filter kernel texture (using the approach described in section 20.2 of GPU Gems 2)
 
void bindFilterKernelTexture() override
bind the filter kernel texture
 
int _lutTextureHeight
power-of-two height of lut texture
 
float getLutHeightScaleFactor() override
 
static GLint desiredLutTextureFormat()
 
ml::GLTexture _kernelTexture
 
int _lutHeight
number of COMPLETE texture rows used by the LUT (an additional row may be used partly)
 
void destroyLutTexture()
frees the lut texture
 
ml::GLTexture _lutTexture
texture that stores the LUT data
 
void bindLutTexture() override
bind the lut texture to the current texture unit
 
int _lutTextureWidth
power-of-two width of lut texture
 
void destroyFilterKernelTexture()
destroy the filter kernel
 
SbVec2s getLutTextureSize() override
 
void updateLutTexture()
upload the lut to the texture (texture must be already created)
 
~View2DTextureLUTShader() override
 
A class to render images as OpenGL Textures.
 
Target mlrange_cast(Source arg)
Generic version of checked ML casts.