Skip to main content

Vec3Component Class Template

Generic 3D value component with dirty-state tracking. More...

Declaration

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args> class helios::engine::core::components::Vec3Component<TDomainTag, TNumericType, THandle, Args> { ... }

Public Member Typedefs Index

template < ... >
usingHandle_type = THandle
template < ... >
usingValue_type = helios::math::vec3< TNumericType >

Public Constructors Index

template < ... >
Vec3Component ()=default
template < ... >
Vec3Component (const Value_type value)

Constructs the component with an initial value. More...

template < ... >
Vec3Component (const TNumericType x, const TNumericType y, const TNumericType z)

Constructs the component from scalar vector coordinates. More...

template < ... >
Vec3Component (const Vec3Component &other)

Copy constructor. More...

template < ... >
Vec3Component (Vec3Component &&) noexcept=default

Default move constructor. More...

Public Operators Index

template < ... >
Vec3Component &operator= (const Vec3Component &)=default

Default copy assignment. More...

template < ... >
Vec3Component &operator= (Vec3Component &&) noexcept=default

Default move assignment. More...

Public Member Functions Index

template < ... >
Value_typevalue () const noexcept

Returns the current value. More...

template < ... >
Value_typevalue () noexcept
template < ... >
voidsetValue (const Value_type value) noexcept

Updates the value and marks the component dirty on change. More...

Private Member Attributes Index

template < ... >
helios::math::vec3< TNumericType >value_ {}

Description

Generic 3D value component with dirty-state tracking.

Template Parameters
TDomainTag

Semantic domain tag.

THandle

Owning entity handle type.

TNumericType

Scalar type for vector values.

Definition at line 24 of file Vec3Component.ixx.

Public Member Typedefs

Handle_type

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
using helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Handle_type = THandle

Definition at line 30 of file Vec3Component.ixx.

30 using Handle_type = THandle;

Value_type

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
using helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Value_type = helios::math::vec3<TNumericType>

Definition at line 31 of file Vec3Component.ixx.

31 using Value_type = helios::math::vec3<TNumericType>;

Public Constructors

Vec3Component()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Vec3Component ()
default

Definition at line 33 of file Vec3Component.ixx.

Vec3Component()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Vec3Component (const Value_type value)
inline explicit

Constructs the component with an initial value.

Parameters
value

Initial value vector.

Definition at line 40 of file Vec3Component.ixx.

40 explicit Vec3Component(const Value_type value) : value_(value){}

Vec3Component()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Vec3Component (const TNumericType x, const TNumericType y, const TNumericType z)
inline explicit

Constructs the component from scalar vector coordinates.

Parameters
x

X component.

y

Y component.

z

Z component.

Definition at line 49 of file Vec3Component.ixx.

49 explicit Vec3Component(
50 const TNumericType x, const TNumericType y, const TNumericType z)
51 : value_(x, y, z){}

Vec3Component()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Vec3Component (const Vec3Component & other)
inline

Copy constructor.

Copies the value and forces the copied component into a dirty state to ensure dependent systems refresh cached data.

Parameters
other

The component to copy from.

Definition at line 61 of file Vec3Component.ixx.

62 value_(other.value_) {}

Vec3Component()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::Vec3Component (Vec3Component &&)
noexcept default

Default move constructor.

Definition at line 67 of file Vec3Component.ixx.

Public Operators

operator=()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
Vec3Component & helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::operator= (const Vec3Component &)
default

Default copy assignment.

Definition at line 65 of file Vec3Component.ixx.

operator=()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
Vec3Component & helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::operator= (Vec3Component &&)
noexcept default

Default move assignment.

Definition at line 69 of file Vec3Component.ixx.

Public Member Functions

setValue()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
void helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::setValue (const Value_type value)
inline noexcept

Updates the value and marks the component dirty on change.

Parameters
value

New value vector.

Definition at line 90 of file Vec3Component.ixx.

90 void setValue(const Value_type value) noexcept {
91 value_ = value;
92 };

Reference helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::value.

value()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
Value_type helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::value ()
inline noexcept

Returns the current value.

Returns

Current 3D vector value.

Definition at line 77 of file Vec3Component.ixx.

78 return value_;
79 }

Referenced by helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::setValue.

value()

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
Value_type helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::value ()
inline noexcept

Definition at line 81 of file Vec3Component.ixx.

82 return value_;
83 }

Private Member Attributes

value_

template <typename TDomainTag, typename TNumericType, typename THandle, typename ... Args>
helios::math::vec3<TNumericType> helios::engine::core::components::Vec3Component< TDomainTag, TNumericType, THandle, Args >::value_ {}

Definition at line 26 of file Vec3Component.ixx.

26 helios::math::vec3<TNumericType> value_{};

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


Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.9.8.