nodeinput: added convenience function for determining if a value is expected to change over time

This commit is contained in:
itsmattkc
2020-06-12 03:27:52 +10:00
parent b3d7158e8e
commit a6a5c113ca
2 changed files with 12 additions and 0 deletions
+5
View File
@@ -970,6 +970,11 @@ bool NodeInput::is_keyframable() const
return keyframable_;
}
bool NodeInput::is_static() const
{
return !(this->is_connected() || this->is_keyframing());
}
QVariant NodeInput::get_standard_value() const
{
return combine_track_values_into_normal_value(standard_value_);
+7
View File
@@ -200,6 +200,13 @@ public:
*/
bool is_keyframable() const;
/**
* @brief Returns whether the value that this input returns is always the same or is expected to change
*
* Equivalent to `!(is_connected() || is_keyframing())`
*/
bool is_static() const;
/**
* @brief Get non-keyframed value
*/