Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2018-12-06 19:52:37 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2018-12-07 13:37:38 +0300
commit79312c1912b4fdb830e38a856cf88bfca8e4703d (patch)
tree74d5b262de9cd5d044e1963df13f2cbe73c3b796 /source/blender/depsgraph
parent989fbff16f49204ca31a67f56f87c2221e0246f4 (diff)
Depsgraph: Remove duplicated sets of recalc/update flags
There were at least three copies of those: - OB_RECALC* family of flags, which are rudiment of an old dependency graph system. - PSYS_RECALC* which were used by old dependency graph system as a separate set since the graph itself did not handle particle systems. - DEG_TAG_* which was used to tag IDs. Now there is a single set, which defines what can be tagged and queried for an update. It also has some aggregate flags to make queries simpler. Lets once and for all solve the madness of those flags, stick to a single set, which will not overlap with anything or require any extra conversion. Technically, shouldn't be measurable user difference, but some of the agregate flags for few dependency graph components did change. Fixes T58632: Particle don't update rotation settings
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r--source/blender/depsgraph/DEG_depsgraph.h39
-rw-r--r--source/blender/depsgraph/intern/builder/deg_builder.cc10
-rw-r--r--source/blender/depsgraph/intern/depsgraph_tag.cc102
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc2
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_flush.cc4
-rw-r--r--source/blender/depsgraph/intern/nodes/deg_node_component.cc15
6 files changed, 72 insertions, 100 deletions
diff --git a/source/blender/depsgraph/DEG_depsgraph.h b/source/blender/depsgraph/DEG_depsgraph.h
index 4cfeb206b97..410f5554069 100644
--- a/source/blender/depsgraph/DEG_depsgraph.h
+++ b/source/blender/depsgraph/DEG_depsgraph.h
@@ -55,6 +55,8 @@
#ifndef __DEG_DEPSGRAPH_H__
#define __DEG_DEPSGRAPH_H__
+#include "DNA_ID.h"
+
/* Dependency Graph */
typedef struct Depsgraph Depsgraph;
@@ -122,39 +124,7 @@ void DEG_graph_on_visible_update(struct Main *bmain, Depsgraph *depsgraph);
/* Update all dependency graphs when visible scenes/layers changes. */
void DEG_on_visible_update(struct Main *bmain, const bool do_time);
-/* Tag given ID for an update in all the dependency graphs. */
-typedef enum eDepsgraph_Tag {
- /* Object transformation changed, corresponds to OB_RECALC_OB. */
- DEG_TAG_TRANSFORM = (1 << 0),
- /* Object geometry changed, corresponds to OB_RECALC_DATA. */
- DEG_TAG_GEOMETRY = (1 << 1),
- /* Time changed and animation is to be re-evaluated, OB_RECALC_TIME. */
- DEG_TAG_TIME = (1 << 2),
- /* Particle system changed; values are aligned with PSYS_RECALC_xxx. */
- DEG_TAG_PSYS_REDO = (1 << 3),
- DEG_TAG_PSYS_RESET = (1 << 4),
- DEG_TAG_PSYS_TYPE = (1 << 5),
- DEG_TAG_PSYS_CHILD = (1 << 6),
- DEG_TAG_PSYS_PHYS = (1 << 7),
- DEG_TAG_PSYS_ALL = (DEG_TAG_PSYS_REDO |
- DEG_TAG_PSYS_RESET |
- DEG_TAG_PSYS_TYPE |
- DEG_TAG_PSYS_CHILD |
- DEG_TAG_PSYS_PHYS),
- /* Update copy on write component without flushing down the road. */
- DEG_TAG_COPY_ON_WRITE = (1 << 8),
- /* Tag shading components for update.
- * Only parameters of material changed).
- */
- DEG_TAG_SHADING_UPDATE = (1 << 9),
- DEG_TAG_SELECT_UPDATE = (1 << 10),
- DEG_TAG_BASE_FLAGS_UPDATE = (1 << 11),
- DEG_TAG_POINT_CACHE_UPDATE = (1 << 12),
- /* Only inform editors about the change. Don't modify datablock itself. */
- DEG_TAG_EDITORS_UPDATE = (1 << 13),
-} eDepsgraph_Tag;
-
-const char *DEG_update_tag_as_string(eDepsgraph_Tag flag);
+const char *DEG_update_tag_as_string(IDRecalcFlag flag);
void DEG_id_tag_update(struct ID *id, int flag);
void DEG_id_tag_update_ex(struct Main *bmain, struct ID *id, int flag);
@@ -166,8 +136,7 @@ void DEG_graph_id_tag_update(struct Main *bmain,
/* Mark a particular datablock type as having changing. This does
* not cause any updates but is used by external render engines to detect if for
- * example a datablock was removed.
- */
+ * example a datablock was removed. */
void DEG_id_type_tag(struct Main *bmain, short id_type);
void DEG_ids_clear_recalc(struct Main *bmain, Depsgraph *depsgraph);
diff --git a/source/blender/depsgraph/intern/builder/deg_builder.cc b/source/blender/depsgraph/intern/builder/deg_builder.cc
index 3fc54fed623..ab3ca9f70cf 100644
--- a/source/blender/depsgraph/intern/builder/deg_builder.cc
+++ b/source/blender/depsgraph/intern/builder/deg_builder.cc
@@ -135,24 +135,24 @@ void deg_graph_build_finalize(Main *bmain, Depsgraph *graph)
if ((id->recalc & ID_RECALC_ALL)) {
AnimData *adt = BKE_animdata_from_id(id);
if (adt != NULL && (adt->recalc & ADT_RECALC_ANIM) != 0) {
- flag |= DEG_TAG_TIME;
+ flag |= ID_RECALC_ANIMATION;
}
}
/* Tag rebuild if special evaluation flags changed. */
if (id_node->eval_flags != id_node->previous_eval_flags) {
- flag |= DEG_TAG_TRANSFORM | DEG_TAG_GEOMETRY;
+ flag |= ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY;
}
/* Tag rebuild if the custom data mask changed. */
if (id_node->customdata_mask != id_node->previous_customdata_mask) {
- flag |= DEG_TAG_GEOMETRY;
+ flag |= ID_RECALC_GEOMETRY;
}
if (!deg_copy_on_write_is_expanded(id_node->id_cow)) {
- flag |= DEG_TAG_COPY_ON_WRITE;
+ flag |= ID_RECALC_COPY_ON_WRITE;
/* This means ID is being added to the dependency graph first
* time, which is similar to "ob-visible-change"
*/
if (GS(id->name) == ID_OB) {
- flag |= OB_RECALC_OB | OB_RECALC_DATA;
+ flag |= ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY;
}
}
if (flag != 0) {
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index 6374354a154..491548e7a18 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -143,7 +143,7 @@ void depsgraph_base_flags_tag_to_component_opcode(
}
void depsgraph_tag_to_component_opcode(const ID *id,
- eDepsgraph_Tag tag,
+ IDRecalcFlag tag,
eDepsNode_Type *component_type,
eDepsOperation_Code *operation_code)
{
@@ -157,20 +157,20 @@ void depsgraph_tag_to_component_opcode(const ID *id,
return;
}
switch (tag) {
- case DEG_TAG_TRANSFORM:
+ case ID_RECALC_TRANSFORM:
*component_type = DEG_NODE_TYPE_TRANSFORM;
break;
- case DEG_TAG_GEOMETRY:
+ case ID_RECALC_GEOMETRY:
depsgraph_geometry_tag_to_component(id, component_type);
break;
- case DEG_TAG_TIME:
+ case ID_RECALC_ANIMATION:
*component_type = DEG_NODE_TYPE_ANIMATION;
break;
- case DEG_TAG_PSYS_REDO:
- case DEG_TAG_PSYS_RESET:
- case DEG_TAG_PSYS_TYPE:
- case DEG_TAG_PSYS_CHILD:
- case DEG_TAG_PSYS_PHYS:
+ case ID_RECALC_PSYS_REDO:
+ case ID_RECALC_PSYS_RESET:
+ case ID_RECALC_PSYS_YPE:
+ case ID_RECALC_PSYS_CHILD:
+ case ID_RECALC_PSYS_PHYS:
if (id_type == ID_PA) {
/* NOTES:
* - For particle settings node we need to use different
@@ -184,10 +184,10 @@ void depsgraph_tag_to_component_opcode(const ID *id,
*component_type = DEG_NODE_TYPE_EVAL_PARTICLES;
}
break;
- case DEG_TAG_COPY_ON_WRITE:
+ case ID_RECALC_COPY_ON_WRITE:
*component_type = DEG_NODE_TYPE_COPY_ON_WRITE;
break;
- case DEG_TAG_SHADING_UPDATE:
+ case ID_RECALC_SHADING:
if (id_type == ID_NT) {
*component_type = DEG_NODE_TYPE_SHADING_PARAMETERS;
}
@@ -195,25 +195,26 @@ void depsgraph_tag_to_component_opcode(const ID *id,
*component_type = DEG_NODE_TYPE_SHADING;
}
break;
- case DEG_TAG_SELECT_UPDATE:
+ case ID_RECALC_SELECT:
depsgraph_select_tag_to_component_opcode(id,
component_type,
operation_code);
break;
- case DEG_TAG_BASE_FLAGS_UPDATE:
+ case ID_RECALC_BASE_FLAGS:
depsgraph_base_flags_tag_to_component_opcode(id,
component_type,
operation_code);
break;
- case DEG_TAG_POINT_CACHE_UPDATE:
+ case ID_RECALC_POINT_CACHE:
*component_type = DEG_NODE_TYPE_POINT_CACHE;
break;
- case DEG_TAG_EDITORS_UPDATE:
+ case ID_RECALC_EDITORS:
/* There is no such node in depsgraph, this tag is to be handled
* separately.
*/
break;
- case DEG_TAG_PSYS_ALL:
+ case ID_RECALC_ALL:
+ case ID_RECALC_PSYS_ALL:
BLI_assert(!"Should not happen");
break;
}
@@ -273,16 +274,16 @@ void depsgraph_tag_component(Depsgraph *graph,
/* This is a tag compatibility with legacy code.
*
- * Mainly, old code was tagging object with OB_RECALC_DATA tag to inform
+ * Mainly, old code was tagging object with ID_RECALC_GEOMETRY tag to inform
* that object's data datablock changed. Now API expects that ID is given
* explicitly, but not all areas are aware of this yet.
*/
void deg_graph_id_tag_legacy_compat(Main *bmain,
Depsgraph *depsgraph,
ID *id,
- eDepsgraph_Tag tag)
+ IDRecalcFlag tag)
{
- if (tag == DEG_TAG_GEOMETRY || tag == 0) {
+ if (tag == ID_RECALC_GEOMETRY || tag == 0) {
switch (GS(id->name)) {
case ID_OB:
{
@@ -334,9 +335,9 @@ static void deg_graph_id_tag_update_single_flag(Main *bmain,
Depsgraph *graph,
ID *id,
IDDepsNode *id_node,
- eDepsgraph_Tag tag)
+ IDRecalcFlag tag)
{
- if (tag == DEG_TAG_EDITORS_UPDATE) {
+ if (tag == ID_RECALC_EDITORS) {
if (graph != NULL) {
depsgraph_update_editors_tag(bmain, graph, id);
}
@@ -380,7 +381,7 @@ static void deg_graph_id_tag_update_single_flag(Main *bmain,
}
-string stringify_append_bit(const string& str, eDepsgraph_Tag tag)
+string stringify_append_bit(const string& str, IDRecalcFlag tag)
{
string result = str;
if (!result.empty()) {
@@ -400,13 +401,13 @@ string stringify_update_bitfield(int flag)
/* Special cases to avoid ALL flags form being split into
* individual bits.
*/
- if ((current_flag & DEG_TAG_PSYS_ALL) == DEG_TAG_PSYS_ALL) {
- result = stringify_append_bit(result, DEG_TAG_PSYS_ALL);
+ if ((current_flag & ID_RECALC_PSYS_ALL) == ID_RECALC_PSYS_ALL) {
+ result = stringify_append_bit(result, ID_RECALC_PSYS_ALL);
}
/* Handle all the rest of the flags. */
while (current_flag != 0) {
- eDepsgraph_Tag tag =
- (eDepsgraph_Tag)(1 << bitscan_forward_clear_i(&current_flag));
+ IDRecalcFlag tag =
+ (IDRecalcFlag)(1 << bitscan_forward_clear_i(&current_flag));
result = stringify_append_bit(result, tag);
}
return result;
@@ -425,7 +426,7 @@ void deg_graph_node_tag_zero(Main *bmain, Depsgraph *graph, IDDepsNode *id_node)
}
ID *id = id_node->id_orig;
/* TODO(sergey): Which recalc flags to set here? */
- id->recalc |= ID_RECALC_ALL & ~(DEG_TAG_PSYS_ALL | ID_RECALC_ANIMATION);
+ id->recalc |= ID_RECALC_ALL & ~(ID_RECALC_PSYS_ALL | ID_RECALC_ANIMATION);
GHASH_FOREACH_BEGIN(ComponentDepsNode *, comp_node, id_node->components)
{
if (comp_node->type == DEG_NODE_TYPE_ANIMATION) {
@@ -434,7 +435,7 @@ void deg_graph_node_tag_zero(Main *bmain, Depsgraph *graph, IDDepsNode *id_node)
comp_node->tag_update(graph, DEG_UPDATE_SOURCE_USER_EDIT);
}
GHASH_FOREACH_END();
- deg_graph_id_tag_legacy_compat(bmain, graph, id, (eDepsgraph_Tag)0);
+ deg_graph_id_tag_legacy_compat(bmain, graph, id, (IDRecalcFlag)0);
}
void deg_graph_id_tag_update(Main *bmain, Depsgraph *graph, ID *id, int flag)
@@ -454,11 +455,11 @@ void deg_graph_id_tag_update(Main *bmain, Depsgraph *graph, ID *id, int flag)
if (flag == 0) {
deg_graph_node_tag_zero(bmain, graph, id_node);
}
- id->recalc |= (flag & PSYS_RECALC);
+ id->recalc |= flag;
int current_flag = flag;
while (current_flag != 0) {
- eDepsgraph_Tag tag =
- (eDepsgraph_Tag)(1 << bitscan_forward_clear_i(&current_flag));
+ IDRecalcFlag tag =
+ (IDRecalcFlag)(1 << bitscan_forward_clear_i(&current_flag));
deg_graph_id_tag_update_single_flag(bmain,
graph,
id,
@@ -471,7 +472,7 @@ void deg_graph_id_tag_update(Main *bmain, Depsgraph *graph, ID *id, int flag)
* physics did change and that cache is to be invalidated.
*/
deg_graph_id_tag_update_single_flag(
- bmain, graph, id, id_node, DEG_TAG_POINT_CACHE_UPDATE);
+ bmain, graph, id, id_node, ID_RECALC_POINT_CACHE);
}
void deg_id_tag_update(Main *bmain, ID *id, int flag)
@@ -509,7 +510,7 @@ void deg_graph_on_visible_update(Main *bmain, Depsgraph *graph)
}
int flag = 0;
if (!DEG::deg_copy_on_write_is_expanded(id_node->id_cow)) {
- flag |= DEG_TAG_COPY_ON_WRITE;
+ flag |= ID_RECALC_COPY_ON_WRITE;
}
/* We only tag components which needs an update. Tagging everything is
* not a good idea because that might reset particles cache (or any
@@ -519,7 +520,7 @@ void deg_graph_on_visible_update(Main *bmain, Depsgraph *graph)
*/
const ID_Type id_type = GS(id_node->id_orig->name);
if (id_type == ID_OB) {
- flag |= OB_RECALC_OB | OB_RECALC_DATA;
+ flag |= ID_RECALC_TRANSFORM | ID_RECALC_GEOMETRY;
}
deg_graph_id_tag_update(bmain, graph, id_node->id_orig, flag);
if (id_type == ID_SCE) {
@@ -583,24 +584,25 @@ eDepsNode_Type deg_geometry_tag_to_component(const ID *id)
} // namespace DEG
-const char *DEG_update_tag_as_string(eDepsgraph_Tag flag)
+const char *DEG_update_tag_as_string(IDRecalcFlag flag)
{
switch (flag) {
- case DEG_TAG_TRANSFORM: return "TRANSFORM";
- case DEG_TAG_GEOMETRY: return "GEOMETRY";
- case DEG_TAG_TIME: return "TIME";
- case DEG_TAG_PSYS_REDO: return "PSYS_REDO";
- case DEG_TAG_PSYS_RESET: return "PSYS_RESET";
- case DEG_TAG_PSYS_TYPE: return "PSYS_TYPE";
- case DEG_TAG_PSYS_CHILD: return "PSYS_CHILD";
- case DEG_TAG_PSYS_PHYS: return "PSYS_PHYS";
- case DEG_TAG_PSYS_ALL: return "PSYS_ALL";
- case DEG_TAG_COPY_ON_WRITE: return "COPY_ON_WRITE";
- case DEG_TAG_SHADING_UPDATE: return "SHADING_UPDATE";
- case DEG_TAG_SELECT_UPDATE: return "SELECT_UPDATE";
- case DEG_TAG_BASE_FLAGS_UPDATE: return "BASE_FLAGS_UPDATE";
- case DEG_TAG_POINT_CACHE_UPDATE: return "POINT_CACHE_UPDATE";
- case DEG_TAG_EDITORS_UPDATE: return "EDITORS_UPDATE";
+ case ID_RECALC_TRANSFORM: return "TRANSFORM";
+ case ID_RECALC_GEOMETRY: return "GEOMETRY";
+ case ID_RECALC_ANIMATION: return "ANIMATION";
+ case ID_RECALC_PSYS_REDO: return "PSYS_REDO";
+ case ID_RECALC_PSYS_RESET: return "PSYS_RESET";
+ case ID_RECALC_PSYS_YPE: return "PSYS_TYPE";
+ case ID_RECALC_PSYS_CHILD: return "PSYS_CHILD";
+ case ID_RECALC_PSYS_PHYS: return "PSYS_PHYS";
+ case ID_RECALC_PSYS_ALL: return "PSYS_ALL";
+ case ID_RECALC_COPY_ON_WRITE: return "COPY_ON_WRITE";
+ case ID_RECALC_SHADING: return "SHADING";
+ case ID_RECALC_SELECT: return "SELECT";
+ case ID_RECALC_BASE_FLAGS: return "BASE_FLAGS";
+ case ID_RECALC_POINT_CACHE: return "POINT_CACHE";
+ case ID_RECALC_EDITORS: return "EDITORS";
+ case ID_RECALC_ALL: return "ALL";
}
BLI_assert(!"Unhandled update flag, should never happen!");
return "UNKNOWN";
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
index f8754c530a0..aa028629093 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
@@ -930,7 +930,7 @@ ID *deg_update_copy_on_write_datablock(const Depsgraph *depsgraph,
* everything is done by node tree update function which
* only copies socket values.
*/
- const int ignore_flag = (ID_RECALC_DRAW |
+ const int ignore_flag = (ID_RECALC_SHADING |
ID_RECALC_ANIMATION |
ID_RECALC_COPY_ON_WRITE);
if ((id_cow->recalc & ~ignore_flag) == 0) {
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_flush.cc b/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
index 61edc1e3795..fef3282cfcc 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_flush.cc
@@ -345,10 +345,10 @@ void invalidate_tagged_evaluated_data(Depsgraph *graph)
continue;
}
switch (comp_node->type) {
- case DEG_TAG_TRANSFORM:
+ case ID_RECALC_TRANSFORM:
invalidate_tagged_evaluated_transform(id_cow);
break;
- case DEG_TAG_GEOMETRY:
+ case ID_RECALC_GEOMETRY:
invalidate_tagged_evaluated_geometry(id_cow);
break;
default:
diff --git a/source/blender/depsgraph/intern/nodes/deg_node_component.cc b/source/blender/depsgraph/intern/nodes/deg_node_component.cc
index dc4661cef53..6840aa0e7e5 100644
--- a/source/blender/depsgraph/intern/nodes/deg_node_component.cc
+++ b/source/blender/depsgraph/intern/nodes/deg_node_component.cc
@@ -384,22 +384,23 @@ void BoneComponentDepsNode::init(const ID *id, const char *subdata)
/* Register all components. =============================== */
DEG_COMPONENT_NODE_DEFINE(Animation, ANIMATION, ID_RECALC_ANIMATION);
-DEG_COMPONENT_NODE_DEFINE(BatchCache, BATCH_CACHE, ID_RECALC_DRAW_CACHE);
+/* TODO(sergey): Is this a correct tag? */
+DEG_COMPONENT_NODE_DEFINE(BatchCache, BATCH_CACHE, ID_RECALC_SHADING);
DEG_COMPONENT_NODE_DEFINE(Bone, BONE, ID_RECALC_GEOMETRY);
-DEG_COMPONENT_NODE_DEFINE(Cache, CACHE, ID_RECALC);
+DEG_COMPONENT_NODE_DEFINE(Cache, CACHE, 0);
DEG_COMPONENT_NODE_DEFINE(CopyOnWrite, COPY_ON_WRITE, ID_RECALC_COPY_ON_WRITE);
DEG_COMPONENT_NODE_DEFINE(Geometry, GEOMETRY, ID_RECALC_GEOMETRY);
DEG_COMPONENT_NODE_DEFINE(LayerCollections, LAYER_COLLECTIONS, 0);
-DEG_COMPONENT_NODE_DEFINE(Parameters, PARAMETERS, ID_RECALC);
+DEG_COMPONENT_NODE_DEFINE(Parameters, PARAMETERS, 0);
DEG_COMPONENT_NODE_DEFINE(Particles, EVAL_PARTICLES, ID_RECALC_GEOMETRY);
DEG_COMPONENT_NODE_DEFINE(PointCache, POINT_CACHE, 0);
DEG_COMPONENT_NODE_DEFINE(Pose, EVAL_POSE, ID_RECALC_GEOMETRY);
DEG_COMPONENT_NODE_DEFINE(Proxy, PROXY, ID_RECALC_GEOMETRY);
-DEG_COMPONENT_NODE_DEFINE(Sequencer, SEQUENCER, ID_RECALC);
-DEG_COMPONENT_NODE_DEFINE(Shading, SHADING, ID_RECALC_DRAW);
-DEG_COMPONENT_NODE_DEFINE(ShadingParameters, SHADING_PARAMETERS, ID_RECALC_DRAW);
+DEG_COMPONENT_NODE_DEFINE(Sequencer, SEQUENCER, 0);
+DEG_COMPONENT_NODE_DEFINE(Shading, SHADING, ID_RECALC_SHADING);
+DEG_COMPONENT_NODE_DEFINE(ShadingParameters, SHADING_PARAMETERS, ID_RECALC_SHADING);
DEG_COMPONENT_NODE_DEFINE(Transform, TRANSFORM, ID_RECALC_TRANSFORM);
-DEG_COMPONENT_NODE_DEFINE(ObjectFromLayer, OBJECT_FROM_LAYER, ID_RECALC);
+DEG_COMPONENT_NODE_DEFINE(ObjectFromLayer, OBJECT_FROM_LAYER, 0);
DEG_COMPONENT_NODE_DEFINE(Dupli, DUPLI, 0);
DEG_COMPONENT_NODE_DEFINE(Synchronize, SYNCHRONIZE, 0);
DEG_COMPONENT_NODE_DEFINE(GenericDatablock, GENERIC_DATABLOCK, 0);