# Visualization Library A lightweight C++ OpenGL middleware for 2D/3D graphics | [Home] [Tutorials] [All Classes] [Grouped Classes]

# E:/VisualizationLibrary/BuildSystem/VL_DISTRO/Visualization_Library_SDK/src/vl/Shader.cpp File Reference

`#include "vl/Shader.hpp"`
`#include "vl/OpenGL.hpp"`
`#include "vl/Log.hpp"`
`#include "vl/Say.hpp"`

## Defines
#define | GET_OR_CREATE(RS)
#define | GET_OR_CREATE_IDX(RS, index)

## Define Documentation

#define GET_OR_CREATE | ( | RS |  | ) |

Value:

    RS* rs = dynamic_cast<RS*>( gocRenderStateSet()->renderState( RS_##RS ) ); \
      if ( rs == NULL ) \
      { \
        rs = new RS; \
        gocRenderStateSet()->setRenderState( rs ); \
      } \
      return rs;

#define GET_OR_CREATE_IDX | ( | RS,
|  | index |  | ) |

Value:

    RS* rs = dynamic_cast<RS*>( gocRenderStateSet()->renderState( (ERenderState)(RS_##RS##0 + index) ) ); \
      if ( rs == NULL ) \
      { \
        rs = new RS(index); \
        gocRenderStateSet()->setRenderState( rs ); \
      } \
      return rs;

Visualization Library v2009.08 Reference Documentation
Copyright 2005-2009 Michele Bosi. All rights reserved.
Updated on Sun Nov 8 14:28:51 2009.
Permission is granted to use this page to write and publish articles regarding Visualization Library.