DEKI/ENGINE docs
Deki 0.19.0
Modular C++ 2D engine for embedded displays and desktop
Loading...
Searching...
No Matches
Property.h File Reference

Classes

struct  Deki::FieldRef
 Compact field descriptor, the one piece of reflection on every platform. More...
struct  Deki::PropertyInfo
 Property metadata, one per component type and field. More...
struct  Deki::ComponentMeta
 Component metadata for runtime reflection. More...

Namespaces

namespace  DekiNodeGraph
namespace  Deki
namespace  Deki::SceneFormat

Macros

#define DEKI_EXPORT
#define DEKI_EDITOR_ONLY
#define DEKI_TOOLTIP(text)
#define DEKI_TOGGLE_OBJECT(field)
#define DEKI_VISIBLE_WHEN(prop, ...)
#define DEKI_VISIBLE_WHEN_RANGE(prop, minVal, maxVal)
#define DEKI_RANGE(minVal, maxVal)
#define DEKI_SLIDER(minVal, maxVal)
#define DEKI_GROUP(name)
#define DEKI_OBJECT_NAME(...)
#define DEKI_VALUE_OF(prop)
#define DEKI_UNIT(unit)
#define DEKI_RENAMED_FROM(oldName)
#define DEKI_SERIALIZABLE
#define DEKI_NO_SERIALIZE
#define DEKI_SERIALIZABLE_NAME(name)
#define DEKI_SERIALIZABLE_DEFAULT_VALUE(val)
#define DEKI_CATEGORY(text)
#define DEKI_DESCRIPTION(text)
#define DEKI_DISPLAY_NAME(text)
#define DEKI_SETTINGS_SECTION(text)
#define DEKI_FORMER_NAME(text)
#define DEKI_NODE_REFLECTION_DECLARATIONS()
#define DEKI_NODE(TypeName, NodeName, Category)
#define DEKI_NODE_INPUTS(...)
#define DEKI_NODE_OUTPUTS(...)
#define DEKI_NODE_DYNAMIC_OUTPUTS(PropName)
#define DEKI_NODE_CHILDREN(Category)
#define DEKI_NODE_SUBGRAPH(ContentCategory, EntryTypeName)
#define DEKI_NODE_TITLE_PROPERTY(PropName)
#define DEKI_NODE_PERMANENT()
#define DEKI_NODE_VARIABLES()

Enumerations

enum class  Deki::PhysicalUnit : uint8_t {
  Deki::None = 0 , Deki::Distance , Deki::Velocity , Deki::Acceleration ,
  Deki::Angle , Deki::AngularVelocity , Deki::Temperature , Deki::Frequency ,
  Deki::Time
}
 Physical unit of a Float or Vector2 property. More...
enum class  Deki::PropertyType : uint8_t {
  Deki::Int8 , Deki::Int16 , Deki::Int32 , Deki::Int64 ,
  Deki::UInt8 , Deki::UInt16 , Deki::UInt32 , Deki::UInt64 ,
  Deki::Float , Deki::Double , Deki::Bool , Deki::String ,
  Deki::Color , Deki::Vector2 , Deki::Vector3 , Deki::Enum ,
  Deki::ObjectRef , Deki::Array , Deki::AssetRef , Deki::NodeRef ,
  Deki::PropertyRef
}
 Property types for runtime reflection. More...

Functions

const char * Deki::EnumNameForValue (const PropertyInfo &prop, int32_t value)
 Name of the enumerator whose underlying value is value, or nullptr when the enum has no such value or the property has no enumInts.
bool Deki::SameNameIgnoringStyle (const char *a, const char *b)
 True when a and b are the same name once underscores are dropped and letter case is ignored: "Portrait_180" and "Portrait180", "READ_BINARY" and "ReadBinary".
bool Deki::EnumValueForName (const PropertyInfo &prop, const char *name, int32_t &out)
 Underlying value of the enumerator called name.
int Deki::EnumIndexForValue (const PropertyInfo &prop, int32_t value)
 Position of value in the enum tables, for a UI that works in list indices such as a combo box.
template<typename T>
T & Deki::GetPropertyRef (Component *comp, const PropertyInfo &prop)
template<typename T>
const T & Deki::GetPropertyRef (const Component *comp, const PropertyInfo &prop)
template<typename T>
T Deki::GetPropertyValue (const Component *comp, const PropertyInfo &prop)
template<typename T>
void Deki::SetPropertyValue (Component *comp, const PropertyInfo &prop, const T &value)
template<typename T>
T & Deki::GetNodePropertyRef (void *base, const PropertyInfo &prop)
template<typename T>
const T & Deki::GetNodePropertyRef (const void *base, const PropertyInfo &prop)

Macro Definition Documentation

◆ DEKI_EXPORT

#define DEKI_EXPORT

◆ DEKI_EDITOR_ONLY

#define DEKI_EDITOR_ONLY

◆ DEKI_TOOLTIP

#define DEKI_TOOLTIP ( text)

◆ DEKI_TOGGLE_OBJECT

#define DEKI_TOGGLE_OBJECT ( field)

◆ DEKI_VISIBLE_WHEN

#define DEKI_VISIBLE_WHEN ( prop,
... )

◆ DEKI_VISIBLE_WHEN_RANGE

#define DEKI_VISIBLE_WHEN_RANGE ( prop,
minVal,
maxVal )

◆ DEKI_RANGE

#define DEKI_RANGE ( minVal,
maxVal )

◆ DEKI_SLIDER

#define DEKI_SLIDER ( minVal,
maxVal )

◆ DEKI_GROUP

#define DEKI_GROUP ( name)

◆ DEKI_OBJECT_NAME

#define DEKI_OBJECT_NAME ( ...)

◆ DEKI_VALUE_OF

#define DEKI_VALUE_OF ( prop)

◆ DEKI_UNIT

#define DEKI_UNIT ( unit)

◆ DEKI_RENAMED_FROM

#define DEKI_RENAMED_FROM ( oldName)

◆ DEKI_SERIALIZABLE

#define DEKI_SERIALIZABLE

◆ DEKI_NO_SERIALIZE

#define DEKI_NO_SERIALIZE

◆ DEKI_SERIALIZABLE_NAME

#define DEKI_SERIALIZABLE_NAME ( name)

◆ DEKI_SERIALIZABLE_DEFAULT_VALUE

#define DEKI_SERIALIZABLE_DEFAULT_VALUE ( val)

◆ DEKI_CATEGORY

#define DEKI_CATEGORY ( text)

◆ DEKI_DESCRIPTION

#define DEKI_DESCRIPTION ( text)

◆ DEKI_DISPLAY_NAME

#define DEKI_DISPLAY_NAME ( text)

◆ DEKI_SETTINGS_SECTION

#define DEKI_SETTINGS_SECTION ( text)

◆ DEKI_FORMER_NAME

#define DEKI_FORMER_NAME ( text)

◆ DEKI_NODE_REFLECTION_DECLARATIONS

#define DEKI_NODE_REFLECTION_DECLARATIONS ( )
Value:
static const ::Deki::PropertyInfo* GetProperties(); \
static int GetPropertyCount(); \
static const ::DekiNodeGraph::DekiNodeMeta& GetNodeMeta();

◆ DEKI_NODE

#define DEKI_NODE ( TypeName,
NodeName,
Category )
Value:
public: \
static constexpr const char* StaticNodeName = NodeName; \
static constexpr const char* StaticNodeCategory = Category; \
DEKI_NODE_REFLECTION_DECLARATIONS()

◆ DEKI_NODE_INPUTS

#define DEKI_NODE_INPUTS ( ...)
Value:
public: \
static constexpr const char* StaticInputPins[] = { __VA_ARGS__ }; \
static constexpr int StaticInputPinCount = \
(int)(sizeof(StaticInputPins) / sizeof(StaticInputPins[0]));

◆ DEKI_NODE_OUTPUTS

#define DEKI_NODE_OUTPUTS ( ...)
Value:
public: \
static constexpr const char* StaticOutputPins[] = { __VA_ARGS__ }; \
static constexpr int StaticOutputPinCount = \
(int)(sizeof(StaticOutputPins) / sizeof(StaticOutputPins[0]));

◆ DEKI_NODE_DYNAMIC_OUTPUTS

#define DEKI_NODE_DYNAMIC_OUTPUTS ( PropName)
Value:
public: \
static constexpr const char* StaticDynamicOutputsProperty = PropName;

◆ DEKI_NODE_CHILDREN

#define DEKI_NODE_CHILDREN ( Category)
Value:
public: \
static constexpr const char* StaticNodeChildCategory = Category;

◆ DEKI_NODE_SUBGRAPH

#define DEKI_NODE_SUBGRAPH ( ContentCategory,
EntryTypeName )
Value:
public: \
static constexpr const char* StaticNodeSubgraphCategory = ContentCategory; \
static constexpr const char* StaticNodeSubgraphEntry = EntryTypeName;

◆ DEKI_NODE_TITLE_PROPERTY

#define DEKI_NODE_TITLE_PROPERTY ( PropName)
Value:
public: \
static constexpr const char* StaticNodeTitleProperty = PropName;

◆ DEKI_NODE_PERMANENT

#define DEKI_NODE_PERMANENT ( )
Value:
public: \
static constexpr bool StaticNodePermanent = true;

◆ DEKI_NODE_VARIABLES

#define DEKI_NODE_VARIABLES ( )
Value:
public: \
static constexpr bool StaticNodeVariables = true;