Antkeeper
0.0.1
|
A property of a material which can be uploaded to a shader program via a shader input. More...
#include <material-property.hpp>
Public Types | |
typedef tween< T > | tween_type |
typedef tween< T >::interpolator_type | interpolator_type |
Public Member Functions | |
material_property (std::size_t element_count) | |
Creates a material property. More... | |
virtual | ~material_property () |
Destroys a material property. More... | |
material_property (const material_property< T > &)=delete | |
material_property< T > & | operator= (const material_property< T > &)=delete |
virtual void | update_tweens () |
Sets state 0 = state 1. More... | |
virtual bool | upload (double a) const |
void | set_value (const T &value) |
Sets the value of this property. More... | |
void | set_value (std::size_t index, const T &value) |
Sets the value of a single element in this array property. More... | |
void | set_values (std::size_t index, const T *values, std::size_t count) |
Sets the values of a range of elements in this array property. More... | |
void | set_tween_interpolator (interpolator_type interpolator) |
Sets the tween interpolator function. More... | |
const T & | get_value () const |
Returns the value of the first element in this property. More... | |
const T & | get_value (std::size_t index) const |
Returns the value of the first element in this property. More... | |
virtual gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
virtual material_property_base * | clone () const |
Creates a copy of this material property. More... | |
float | default_interpolator (const float &x, const float &y, double a) |
float2 | default_interpolator (const float2 &x, const float2 &y, double a) |
float3 | default_interpolator (const float3 &x, const float3 &y, double a) |
float4 | default_interpolator (const float4 &x, const float4 &y, double a) |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
gl::shader_variable_type | get_data_type () const |
Returns the type of data which the property contains. More... | |
![]() | |
bool | connect (const gl::shader_input *input) |
Connects the material property to a shader input. More... | |
void | disconnect () |
Disconnects the material property from its shader input. More... | |
bool | is_connected () const |
Returns true if the material property is connected to a shader input, false otherwise. More... | |
Static Public Member Functions | |
static T | default_interpolator (const T &x, const T &y, double a) |
Default tween interpolator function for this material property type. More... | |
Additional Inherited Members | |
![]() | |
material_property_base () | |
![]() | |
const gl::shader_input * | input |
A property of a material which can be uploaded to a shader program via a shader input.
T | Property data type. |
Definition at line 103 of file material-property.hpp.
typedef tween<T>::interpolator_type render::material_property< T >::interpolator_type |
Definition at line 107 of file material-property.hpp.
typedef tween<T> render::material_property< T >::tween_type |
Definition at line 106 of file material-property.hpp.
render::material_property< T >::material_property | ( | std::size_t | element_count | ) |
Creates a material property.
element_count | Number of elements in the property array. |
Definition at line 217 of file material-property.hpp.
|
virtual |
Destroys a material property.
Definition at line 226 of file material-property.hpp.
|
delete |
|
virtual |
Creates a copy of this material property.
Implements render::material_property_base.
Definition at line 445 of file material-property.hpp.
|
inline |
Definition at line 193 of file material-property.hpp.
|
inline |
Definition at line 199 of file material-property.hpp.
|
inline |
Definition at line 205 of file material-property.hpp.
|
inline |
Definition at line 211 of file material-property.hpp.
|
inlinestatic |
Default tween interpolator function for this material property type.
Definition at line 187 of file material-property.hpp.
|
virtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 307 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 313 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 319 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 325 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 331 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 337 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 343 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 349 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 355 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 361 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 367 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 373 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 379 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 385 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 391 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 397 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 403 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 409 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 415 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 421 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 427 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 433 of file material-property.hpp.
|
inlinevirtual |
Returns the type of data which the property contains.
Implements render::material_property_base.
Definition at line 439 of file material-property.hpp.
|
inline |
Returns the value of the first element in this property.
Definition at line 295 of file material-property.hpp.
|
inline |
Returns the value of the first element in this property.
index | Index of an array element. |
Definition at line 301 of file material-property.hpp.
|
delete |
void render::material_property< T >::set_tween_interpolator | ( | interpolator_type | interpolator | ) |
Sets the tween interpolator function.
interpolator | Tween interpolator function. |
Definition at line 286 of file material-property.hpp.
void render::material_property< T >::set_value | ( | const T & | value | ) |
Sets the value of this property.
value | Value to set. |
Definition at line 265 of file material-property.hpp.
void render::material_property< T >::set_value | ( | std::size_t | index, |
const T & | value | ||
) |
Sets the value of a single element in this array property.
index | Index of an array element. |
value | Value to set. |
Definition at line 271 of file material-property.hpp.
void render::material_property< T >::set_values | ( | std::size_t | index, |
const T * | values, | ||
std::size_t | count | ||
) |
Sets the values of a range of elements in this array property.
index | Index of the first array element to set. |
values | Pointer to an array of values to set. |
count | Number of elements to set. |
Definition at line 277 of file material-property.hpp.
|
virtual |
Sets state 0 = state 1.
Implements render::material_property_base.
Definition at line 232 of file material-property.hpp.
|
virtual |
Implements render::material_property_base.
Definition at line 241 of file material-property.hpp.