![]() |
Radium Engine
1.6.3
|
#include <Core/Utils/Attribs.hpp>
Inheritance diagram for Ra::Core::Utils::Attrib< T >:
Collaboration diagram for Ra::Core::Utils::Attrib< T >:Public Types | |
| using | value_type = T |
| using | Container = VectorArray<T> |
Public Member Functions | |
| Attrib (const std::string &name) | |
| void | resize (size_t s) override |
| Resize the container (value_type must have a default ctor). | |
| Container & | getDataWithLock () |
| const Container & | data () const |
| Read-only acccess to the attribute content. | |
| bool | isFloat () const override |
| Return true if the attribute content is of Scalar type, false otherwise. | |
| bool | isVector2 () const override |
| Return true if the attribute content is of Vector2 type, false otherwise. | |
| bool | isVector3 () const override |
| Return true if the attribute content is of Vector3 type, false otherwise. | |
| bool | isVector4 () const override |
| Return true if the attribute content is of Vector4 type, false otherwise. | |
| template<typename U > | |
| bool | isType () |
| check if attrib is a given type, as in attr.isType<MyMatrix>() | |
| std::unique_ptr< AttribBase > | clone () override |
| size_t | getSize () const override |
| size_t | getNumberOfComponents () const override |
| int | getStride () const override |
| size_t | getBufferSize () const override |
| const void * | dataPtr () const override |
| void | setData (const Container &data) |
| void | setData (Container &&data) |
Public Member Functions inherited from Ra::Core::Utils::AttribBase | |
| AttribBase (const std::string &name) | |
| AttribBase (const AttribBase &)=delete | |
| AttribBase & | operator= (const AttribBase &)=delete |
| std::string | getName () const |
| Return the attribute's name. | |
| void | setName (const std::string &name) |
| Set the attribute's name. | |
| bool | operator== (const AttribBase &rhs) |
Return true if *this and rhs have the same name. | |
| template<typename T > | |
| Attrib< T > & | cast () |
| Downcast from AttribBase to Attrib<T>. | |
| template<typename T > | |
| const Attrib< T > & | cast () const |
| Downcast from AttribBase to Attrib<T>. | |
| bool | isLocked () const |
| void | unlock () |
| Unlock data so another one can gain write access. | |
Public Member Functions inherited from Ra::Core::Utils::ContainerIntrospectionInterface | |
| virtual | ~ContainerIntrospectionInterface () |
| only needed for correct abstract dtor call. | |
Additional Inherited Members | |
Protected Member Functions inherited from Ra::Core::Utils::AttribBase | |
| void | lock (bool isLocked=true) |
An Attrib stores an element of type T for each entry.
Definition at line 99 of file Attribs.hpp.
| using Ra::Core::Utils::Attrib< T >::Container = VectorArray<T> |
Definition at line 103 of file Attribs.hpp.
| using Ra::Core::Utils::Attrib< T >::value_type = T |
Definition at line 102 of file Attribs.hpp.
|
explicit |
Definition at line 495 of file Attribs.hpp.
|
virtual |
Definition at line 499 of file Attribs.hpp.
|
inlineoverridevirtual |
Implements Ra::Core::Utils::AttribBase.
Definition at line 141 of file Attribs.hpp.
|
inline |
Read-only acccess to the attribute content.
Definition at line 532 of file Attribs.hpp.
|
overridevirtual |
Implements Ra::Core::Utils::ContainerIntrospectionInterface.
Definition at line 513 of file Attribs.hpp.
|
overridevirtual |
Implements Ra::Core::Utils::ContainerIntrospectionInterface.
Definition at line 547 of file Attribs.hpp.
|
inline |
Read-write access to the attribute content. lock the content, when done call unlock()
Definition at line 507 of file Attribs.hpp.
|
overridevirtual |
Return the number of components of one element (i.e. for glVertexAttribPointer size argument )
Implements Ra::Core::Utils::ContainerIntrospectionInterface.
Definition at line 579 of file Attribs.hpp.
|
overridevirtual |
ContainerIntrosectionInterface implementation
Implements Ra::Core::Utils::ContainerIntrospectionInterface.
Definition at line 537 of file Attribs.hpp.
|
overridevirtual |
Implements Ra::Core::Utils::ContainerIntrospectionInterface.
Definition at line 542 of file Attribs.hpp.
|
overridevirtual |
Return true if the attribute content is of Scalar type, false otherwise.
Implements Ra::Core::Utils::AttribBase.
Definition at line 552 of file Attribs.hpp.
check if attrib is a given type, as in attr.isType<MyMatrix>()
Definition at line 573 of file Attribs.hpp.
|
overridevirtual |
Return true if the attribute content is of Vector2 type, false otherwise.
Implements Ra::Core::Utils::AttribBase.
Definition at line 557 of file Attribs.hpp.
|
overridevirtual |
Return true if the attribute content is of Vector3 type, false otherwise.
Implements Ra::Core::Utils::AttribBase.
Definition at line 562 of file Attribs.hpp.
|
overridevirtual |
Return true if the attribute content is of Vector4 type, false otherwise.
Implements Ra::Core::Utils::AttribBase.
Definition at line 567 of file Attribs.hpp.
|
overridevirtual |
Resize the container (value_type must have a default ctor).
Implements Ra::Core::Utils::AttribBase.
Definition at line 503 of file Attribs.hpp.
Here is the call graph for this function:| void Ra::Core::Utils::Attrib< T >::setData | ( | const Container & | data | ) |
setAttribData, attrib mustn't be locked (it's asserted).
Definition at line 518 of file Attribs.hpp.
| void Ra::Core::Utils::Attrib< T >::setData | ( | Container && | data | ) |
Definition at line 525 of file Attribs.hpp.