1 #ifndef _RIVE_KEY_FRAME_COLOR_BASE_HPP_
2 #define _RIVE_KEY_FRAME_COLOR_BASE_HPP_
3 #include "animation/keyframe.hpp"
4 #include "core/field_types/core_color_type.hpp"
7 class KeyFrameColorBase : public KeyFrame
10 typedef KeyFrame Super;
13 static const uint16_t typeKey = 37;
15 /// Helper to quickly determine if a core object extends another without
17 bool isTypeOf(uint16_t typeKey) const override
21 case KeyFrameColorBase::typeKey:
22 case KeyFrameBase::typeKey:
29 uint16_t coreType() const override { return typeKey; }
31 static const uint16_t valuePropertyKey = 88;
36 inline int value() const { return m_Value; }
47 bool deserialize(uint16_t propertyKey, BinaryReader& reader) override
51 case valuePropertyKey:
52 m_Value = CoreColorType::deserialize(reader);
55 return KeyFrame::deserialize(propertyKey, reader);
59 virtual void valueChanged() {}