|
Ocean
|
This class implements all 1D fields (fields holding an array of single values). More...
#include <Field1D.h>
Public Types | |
| typedef std::vector< T > | Values |
| Definition of a vector holding the single values. | |
Public Types inherited from Ocean::SceneDescription::Field | |
| enum | Type : uint32_t { TYPE_INVALID = 0u , TYPE_BOOLEAN , TYPE_COLOR , TYPE_FLOAT , TYPE_INT , TYPE_MATRIX3 , TYPE_MATRIX4 , TYPE_NODE , TYPE_ROTATION , TYPE_STRING , TYPE_TIME , TYPE_VECTOR2 , TYPE_VECTOR3 , TYPE_VECTOR4 } |
| Definition of scalar field types. More... | |
Public Member Functions | |
| Field1D ()=default | |
| Creates a new multi value field with no value. | |
| Field1D (const T &value) | |
| Creates a new multi value field by a given initialization value. | |
| Field1D (const T &value, const Timestamp timestamp) | |
| Creates a new multi value field by a given initialization value. | |
| Field1D (const Values &values) | |
| Creates a new multi value field by given initilization values. | |
| Field1D (const Values &values, const Timestamp timestamp) | |
| Creates a new multi value field by given initilization values. | |
| Type | type () const override |
| Returns the type of this field. | |
| unsigned int | dimension () const override |
| Returns the dimension of this field. | |
| const Values & | values () const |
| Returns the values of this field. | |
| Values & | values () |
| Returns the values of this field. | |
| void | setValues (const Values &value) |
| Sets the values of this field and changes the timestamp to the current time. | |
| void | setValues (const Values &value, const Timestamp timestamp) |
| Sets the values of this field and defines an explicit modification timestamp. | |
| bool | assign (const Field &field) override |
| Assigns a field to this field if both field have the identical field type. | |
Public Member Functions inherited from Ocean::SceneDescription::Field | |
| virtual | ~Field () |
| Destructs a field object. | |
| Timestamp | timestamp () const |
| Returns the most recent field modification timestamp. | |
| bool | is0D () const |
| Returns whether this field is a 0D field. | |
| bool | is1D () const |
| Returns whether this field is a 1D field. | |
| bool | isType (const Type type) const |
| Returns whether this field has a given type. | |
| bool | isType (const Type type, const unsigned int dimension) const |
| Returns whether this field has a given type and dimension. | |
| void | setTimestamp (const Timestamp timestamp) |
| Sets the field timestamp explicitly. | |
| Field & | operator= (const Field &field) |
| Assigns a field to this field. | |
Static Public Attributes | |
| static constexpr Type | fieldType = TypeMapper<T>::type() |
| Scalar type of this multi field. | |
| static constexpr unsigned int | fieldDimension = 1u |
| Dimension of this multi field. | |
Protected Member Functions | |
| Field * | copy () const override |
| Returns a new instance of this field. | |
Protected Member Functions inherited from Ocean::SceneDescription::Field | |
| Field ()=default | |
| Creates a new field. | |
| Field (const Field &field)=delete | |
| Disabled copy constructor. | |
| Field (const Timestamp timestamp) | |
| Creates a new field with an explicit modification timestamp. | |
Protected Attributes | |
| Values | values_ |
| Field values. | |
Protected Attributes inherited from Ocean::SceneDescription::Field | |
| Timestamp | timestamp_ |
| Field timestamp. | |
Additional Inherited Members | |
Static Public Member Functions inherited from Ocean::SceneDescription::Field | |
| template<typename T > | |
| static const T & | cast (const Field &field) |
| Casts an unspecific field object to the real field object. | |
This class implements all 1D fields (fields holding an array of single values).
| typedef std::vector<T> Ocean::SceneDescription::Field1D< T >::Values |
Definition of a vector holding the single values.
|
default |
Creates a new multi value field with no value.
|
inline |
Creates a new multi value field by a given initialization value.
The modification timestamp will be set to zero.
| value | Initialization value |
|
inline |
Creates a new multi value field by a given initialization value.
| value | Initialization value |
| timestamp | Explicit field timestamp |
|
inline |
Creates a new multi value field by given initilization values.
The modification timestamp will be set to zero.
| values | Initialization values |
|
inline |
Creates a new multi value field by given initilization values.
| values | Initialization values |
| timestamp | Explicit field timestamp |
|
overridevirtual |
Assigns a field to this field if both field have the identical field type.
Implements Ocean::SceneDescription::Field.
|
overrideprotectedvirtual |
Returns a new instance of this field.
Implements Ocean::SceneDescription::Field.
|
overridevirtual |
Returns the dimension of this field.
Implements Ocean::SceneDescription::Field.
|
inline |
Sets the values of this field and changes the timestamp to the current time.
| value | Values to set |
|
inline |
Sets the values of this field and defines an explicit modification timestamp.
| value | Values to set |
| timestamp | Explicit modification timestamp |
|
overridevirtual |
|
inline |
Returns the values of this field.
|
inline |
Returns the values of this field.
|
staticconstexpr |
Dimension of this multi field.
|
staticconstexpr |
Scalar type of this multi field.
|
protected |
Field values.