Bastien Montagne f188d6709f LibOverride: keep some anim data from liboverride when it exists in both IDs.
So far when an anim data had to be created in liboverride (because none
existed in reference ID), and reference ID got an anim data added later,
that reference anim data would simply replace the one from the
liboverride, completely losing all animation-related work done so far in
the liboverride.

This commit fixes that, by adding some custom handling of anim data when
there is a liboverride operation defined on the `animation_data` RNA
property itself.

It then behaves as if everything that is overridable in the existing
liboverride was defined as overrides (and therefore kept), while
everything else is replaced by the reference animdata:
* Action and temp action are kept.
* Settings (extend mode, etc.) are kept.
* Active NLA track and strip are kept, and tracks and strips from the
  liboverride are added at the end of the list of these from the
  reference data.

Note that this behavior is only expected to happen once, on the first
call to 'apply overrides' after anim data has been added to the reference
linked ID. After that, since both IDs have animdata, there should be no
liboverride property defined for the `animation_data` property itself,
but only for paths leading inside that animdata struct.

Implements #110067.
2023-08-15 16:05:25 +02:00
2023-08-10 22:40:27 +02:00

Blender

Blender is the free and open source 3D creation suite. It supports the entirety of the 3D pipeline-modeling, rigging, animation, simulation, rendering, compositing, motion tracking and video editing.

Blender screenshot

Project Pages

Development

License

Blender as a whole is licensed under the GNU General Public License, Version 3. Individual files may have a different, but compatible license.

See blender.org/about/license for details.

Description
Languages
C++ 78%
Python 14.9%
C 3%
GLSL 1.8%
CMake 1.2%
Other 0.9%