Blender Git Loki

Git Commits -> Revision 98bee41

Revision 98bee41 by Sybren A. Stüvel (master)
July 7, 2020, 12:30 (GMT)
IO: Reversed persistent ID order in exports to Alembic and USD

Each duplicated (a.k.a. instanced) object has a Persistent ID, which
identifies a dupli within the context of its duplicator. This ID
consists of several numbers when there are nested duplis (for example a
mesh instancing empties on its vertices, where each empty instances a
collection). When exporting to Alembic/USD, these are used to uniquely
name the duplicated objects in the export.

This commit reverses the order of the persistent ID numbers, so that the
first number identifies the first level of recursion. This produces
trees like this:

ABC
`--Triangle
|--Triangle
|--Empty-1
| `--Pole-1-0
| |--Pole
| `--Block-1-1
| `--Block
|--Empty
| `--Pole-0
| |--Pole
| `--Block-1
| `--Block
|--Empty-2
| `--Pole-2-0
| |--Pole
| `--Block-2-1
| `--Block
`--Empty-0
`--Pole-0-0
|--Pole
`--Block-0-1
`--Block

It is now clearer that `Pole-2-0` and `Block-2-1` are instanced by
`Empty-2`. Before this commit, they would have been named `Pole-0-2` and
`Block-1-2`.

Commit Details:

Full Hash: 98bee41c8a3f78c612f0c4ee587fceb2730f26b4
Parent Commit: 70b1c09
Lines Changed: +78, -16

5 Modified Paths:

/source/blender/io/common/intern/abstract_hierarchy_iterator.cc (+4, -4) (Diff)
/source/blender/io/common/intern/dupli_persistent_id.cc (+22, -0) (Diff)
/source/blender/io/common/IO_dupli_persistent_id.hh (+7, -0) (Diff)
/tests/gtests/usd/object_identifier_test.cc (+35, -2) (Diff)
/tests/python/alembic_tests.py (+10, -10) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021