VAPOR3 3.9.4
Public Member Functions | Friends | List of all members
VAPoR::SmartShaderProgram Class Reference

Provides a C++ interface to the OpenGL shader program construct. More...

#include <ShaderProgram.h>

Public Member Functions

 SmartShaderProgram (ShaderProgram *program)
 
 ~SmartShaderProgram ()
 
ShaderProgramoperator-> ()
 
bool IsValid () const
 

Friends

class ShaderManager
 

Detailed Description

Provides a C++ interface to the OpenGL shader program construct.

Author
Stanislaw Jaroszynski
Date
August, 2018

This class causes shaders to automatically bind when requested from the ShaderManager. Once the object becomes out of scope, the shader is unbound. Since this class is intended to be used as an object, not a pointer, IsValid replaces the usual NULL check

Definition at line 111 of file ShaderProgram.h.

Constructor & Destructor Documentation

◆ SmartShaderProgram()

VAPoR::SmartShaderProgram::SmartShaderProgram ( ShaderProgram program)

◆ ~SmartShaderProgram()

VAPoR::SmartShaderProgram::~SmartShaderProgram ( )

Member Function Documentation

◆ IsValid()

bool VAPoR::SmartShaderProgram::IsValid ( ) const

◆ operator->()

ShaderProgram * VAPoR::SmartShaderProgram::operator-> ( )
inline

Definition at line 117 of file ShaderProgram.h.

Friends And Related Function Documentation

◆ ShaderManager

friend class ShaderManager
friend

Definition at line 119 of file ShaderProgram.h.


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