22 #ifndef vtkOpenGLShaderCache_h
23 #define vtkOpenGLShaderCache_h
25 #include "vtkRenderingOpenGL2Module.h"
43 const char *vertexCode,
44 const char *fragmentCode,
45 const char *geometryCode,
52 std::map<vtkShader::Type,vtkShader *> shaders,
90 const char *fragmentCode,
91 const char *geometryCode);
93 std::map<vtkShader::Type,vtkShader *> shaders);
a simple class to control print indentation
abstract base class for most VTK objects
manage Shader Programs within a context
virtual vtkShaderProgram * ReadyShaderProgram(vtkShaderProgram *shader, vtkTransformFeedback *cap=NULL)
virtual int BindShader(vtkShaderProgram *shader)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkOpenGLShaderCache * New()
vtkShaderProgram * LastShaderBound
void ReleaseCurrentShader()
Release the current shader.
virtual unsigned int ReplaceShaderValues(std::string &VSSource, std::string &FSSource, std::string &GSSource)
virtual vtkShaderProgram * ReadyShaderProgram(const char *vertexCode, const char *fragmentCode, const char *geometryCode, vtkTransformFeedback *cap=NULL)
virtual vtkShaderProgram * GetShaderProgram(const char *vertexCode, const char *fragmentCode, const char *geometryCode)
virtual void ReleaseGraphicsResources(vtkWindow *win)
Free up any resources being used by the provided shader.
virtual vtkShaderProgram * ReadyShaderProgram(std::map< vtkShader::Type, vtkShader * > shaders, vtkTransformFeedback *cap=NULL)
virtual vtkShaderProgram * GetShaderProgram(std::map< vtkShader::Type, vtkShader * > shaders)
virtual void ClearLastShaderBound()
Get/Clear the last Shader bound, called by shaders as they release their graphics resources.
The ShaderProgram uses one or more Shader objects.
window superclass for vtkRenderWindow