Blender Git Commit Log

Git Commits -> Revision 196d616

Revision 196d616 by Bastien Montagne (master)
October 8, 2020, 16:19 (GMT)
Refactor CustomData interpolation code.

- Move some security checks outside of `interp` callbacks.
Namely, that we do get interpolation weights, and have something to
interpolate.
Some callbacks where not checking on those anyway, safer to move that
up into calling code.

- Cleanup usage of sub-weights, lots of interpolation callbacks wher
actually using those completely wrong.

- Change default behavior when no weights are given to higher-level API
functions: prevriously, each callback was responsible to handle that
case (and one did not even do it!), they were switching to purely
additive behavior then.
Instead, we now default to expected simple average of source values.

Note that the only real important change here is defaulting to actual
average of source value when no inertpolation weights are given (afaik,
this only happens in Weld modifier code).

Differential Revision: https://developer.blender.org/D9114

Commit Details:

Full Hash: 196d6166e51dc9496a8a678c329758134988eee3
Parent Commit: cac0e78
Lines Changed: +136, -145

1 Modified Path:

/source/blender/blenkernel/intern/customdata.c (+136, -145) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021