This is a small container class that can hold any one of the value types that can be passed as input to a shader. More...
#include "shaderInput.h"
Public Member Functions | |
ShaderInput (CPT_InternalName name, int priority=0) | |
ShaderInput (CPT_InternalName name, Texture *tex, int priority=0) | |
ShaderInput (CPT_InternalName name, ParamValueBase *param, int priority=0) | |
ShaderInput (CPT_InternalName name, ShaderBuffer *buf, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_float &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase4f &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase3f &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase2f &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LMatrix4f &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LMatrix3f &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase4f &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase3f &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase2f &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LMatrix4f &mat, int priority=0) | |
ShaderInput (CPT_InternalName name, const LMatrix3f &mat, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_double &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase4d &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase3d &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase2d &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LMatrix4d &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LMatrix3d &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase4d &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase3d &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase2d &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LMatrix4d &mat, int priority=0) | |
ShaderInput (CPT_InternalName name, const LMatrix3d &mat, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_int &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase4i &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase3i &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const PTA_LVecBase2i &ptr, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase4i &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase3i &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const LVecBase2i &vec, int priority=0) | |
ShaderInput (CPT_InternalName name, const NodePath &np, int priority=0) | |
ShaderInput (CPT_InternalName name, Texture *tex, bool read, bool write, int z=-1, int n=0, int priority=0) | |
ShaderInput (CPT_InternalName name, Texture *tex, const SamplerState &sampler, int priority=0) | |
size_t | add_hash (size_t hash) const |
const InternalName * | get_name () const |
const NodePath & | get_nodepath () const |
Warning: no error checking is done. More... | |
ParamValueBase * | get_param () const |
int | get_priority () const |
const Shader::ShaderPtrData & | get_ptr () const |
const SamplerState & | get_sampler () const |
Warning: no error checking is done. More... | |
Texture * | get_texture () const |
TypedWritableReferenceCount * | get_value () const |
int | get_value_type () const |
const LVecBase4 & | get_vector () const |
bool | operator != (const ShaderInput &other) const |
operator bool () const | |
bool | operator< (const ShaderInput &other) const |
bool | operator== (const ShaderInput &other) const |
Static Public Member Functions | |
static const ShaderInput & | get_blank () |
Returns a static ShaderInput object with name NULL, priority zero, type INVALID, and all value-fields cleared. More... | |
static void | register_with_read_factory () |
Friends | |
class | Extension< ShaderInput > |
class | ShaderAttrib |
This is a small container class that can hold any one of the value types that can be passed as input to a shader.
Definition at line 40 of file shaderInput.h.
|
static |
Returns a static ShaderInput object with name NULL, priority zero, type INVALID, and all value-fields cleared.
Definition at line 23 of file shaderInput.cxx.
const NodePath & ShaderInput::get_nodepath | ( | ) | const |
Warning: no error checking is done.
This *will* crash if get_value_type() is not M_nodepath.
Definition at line 93 of file shaderInput.cxx.
const SamplerState & ShaderInput::get_sampler | ( | ) | const |
Warning: no error checking is done.
Definition at line 121 of file shaderInput.cxx.