Public Member Functions | List of all members
HPS::ShaderDefinition Class Reference

#include <hps.h>

Inheritance diagram for HPS::ShaderDefinition:
HPS::Definition HPS::Object

Public Member Functions

 ShaderDefinition ()
 
 ShaderDefinition (Definition const &in_that)
 
 ShaderDefinition (ShaderDefinition const &in_that)
 
ShaderDefinitionoperator= (ShaderDefinition const &in_that)
 
 ShaderDefinition (ShaderDefinition &&in_that)
 
ShaderDefinitionoperator= (ShaderDefinition &&in_that)
 
HPS::Type ObjectType () const
 
void Set (ShaderKit const &in_kit)
 
void Show (ShaderKit &out_kit) const
 
- Public Member Functions inherited from HPS::Definition
 Definition ()
 
 Definition (Definition const &in_that)
 
Definitionoperator= (Definition const &in_that)
 
 Definition (Definition &&in_that)
 
Definitionoperator= (Definition &&in_that)
 
void Undefine ()
 
PortfolioKey Owner () const
 
UTF8 Name () const
 
virtual void Assign (Definition const &in_that)
 
bool Equals (Definition const &in_that) const
 
bool operator== (Definition const &in_that) const
 
bool operator!= (Definition const &in_that) const
 
- Public Member Functions inherited from HPS::Object
Objectoperator= (Object const &other_object)
 
 Object (Object &&in_that)
 
Objectoperator= (Object &&in_that)
 
HPS::Type Type () const
 
virtual bool Empty () const
 
virtual void Reset ()
 
bool HasType (HPS::Type in_mask) const
 
intptr_t GetClassID () const
 
intptr_t GetInstanceID () const
 

Additional Inherited Members

- Static Public Member Functions inherited from HPS::Object
template<typename T >
static intptr_t ClassID ()
 

Detailed Description

The ShaderDefinition class is a smart pointer to a database object. It is a handle to a shader defined within a portfolio.

Constructor & Destructor Documentation

HPS::ShaderDefinition::ShaderDefinition ( )

The default constructor creates an uninitialized ShaderDefinition object. The Type() function will return Type::None.

HPS::ShaderDefinition::ShaderDefinition ( Definition const &  in_that)

This constructor creates a ShaderDefinition object that shares the underlying smart-pointer of the source Definition. The copy will only be successful if the source definition is really an upcast of a shader definition. Otherwise the copy will fail and the resulting ShaderDefinition will be invalid.

Parameters
in_thatThe source Definition to copy.
HPS::ShaderDefinition::ShaderDefinition ( ShaderDefinition const &  in_that)

The copy constructor creates a ShaderDefinition object that shares the underlying smart-pointer of the source ShaderDefinition.

Parameters
in_thatThe source ShaderDefinition to copy.
HPS::ShaderDefinition::ShaderDefinition ( ShaderDefinition &&  in_that)

The move constructor creates a ShaderDefinition by transferring the underlying impl of the rvalue reference to this ShaderDefinition thereby avoiding a copy and allocation.

Parameters
in_thatAn rvalue reference to a ShaderDefinition to take the impl from.

Member Function Documentation

HPS::Type HPS::ShaderDefinition::ObjectType ( ) const
inlinevirtual

This function returns the type the object, as declared. This does not necessarily give the true type of the underlying object.

Returns
The declared type of the object in question, which may differ from the true, underlying type.

Reimplemented from HPS::Definition.

ShaderDefinition& HPS::ShaderDefinition::operator= ( ShaderDefinition const &  in_that)

Associate this ShaderDefinition with the same underlying impl as the source ShaderDefinition.

Parameters
in_thatThe source ShaderDefinition for the assignment.
Returns
A reference to this ShaderDefinition.
ShaderDefinition& HPS::ShaderDefinition::operator= ( ShaderDefinition &&  in_that)

The move assignment operator transfers the underlying impl of the rvalue reference to this ShaderDefinition thereby avoiding a copy.

Parameters
in_thatAn rvalue reference to a ShaderDefinition to take the impl from.
Returns
A reference to this ShaderDefinition.
void HPS::ShaderDefinition::Set ( ShaderKit const &  in_kit)

Redefine the shader for this ShaderDefinition.

Parameters
in_kitThe new shader for this ShaderDefinition.
void HPS::ShaderDefinition::Show ( ShaderKit out_kit) const

Shows the shader for this ShaderDefinition.

Parameters
out_kitThe shader for this ShaderDefinition.

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