diff options
author | Kévin Dietrich <kevin.dietrich@mailoo.org> | 2016-08-08 18:51:15 +0300 |
---|---|---|
committer | Kévin Dietrich <kevin.dietrich@mailoo.org> | 2016-08-08 18:51:15 +0300 |
commit | b745a2401b6ccf75b1e90cf1c8fa648d99c81e29 (patch) | |
tree | 588ff3dea069e483d0a9c09ae8431b9f445d1cce /source/blender/blenkernel/BKE_idcode.h | |
parent | 5e5d3d6391448d30c1946452aeaf3086f28ad875 (diff) |
Fix ID types DAG update tagging.
The first character of the ID type was used to tag IDs for updates which
is weak since different IDs can have the same first character (for
example meshes, materials and metaballs), causing unnecessary updates of
unrelated IDs.
Now we use a unique index per ID type to tag for updates, unifying IDs
arrays indexing along the way.
Reviewers: sergey, mont29
Differential Revision: https://developer.blender.org/D2139
Diffstat (limited to 'source/blender/blenkernel/BKE_idcode.h')
-rw-r--r-- | source/blender/blenkernel/BKE_idcode.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/blenkernel/BKE_idcode.h b/source/blender/blenkernel/BKE_idcode.h index 6de0efe2709..964a49435f1 100644 --- a/source/blender/blenkernel/BKE_idcode.h +++ b/source/blender/blenkernel/BKE_idcode.h @@ -42,6 +42,8 @@ bool BKE_idcode_is_valid(short idcode); int BKE_idcode_to_idfilter(const short idcode); short BKE_idcode_from_idfilter(const int idfilter); +int BKE_idcode_to_index(const short idcode); + /** * Return an ID code and steps the index forward 1. * |