Fix: Skip mixing enum/reference index attributes in simulation bake
Interpolating these attributes as integer values isn't meaningful or helpful and is potentially problematic. So far I'd guess this is unlikely to happen in practice which is why it probably hasn't been noticed yet. Fixes part of #129691. Pull Request: https://projects.blender.org/blender/blender/pulls/129809
This commit is contained in:
@@ -176,12 +176,13 @@ bke::GeometrySet mix_geometries(bke::GeometrySet a, const bke::GeometrySet &b, c
|
||||
bke::MutableAttributeAccessor a = curves_a->geometry.wrap().attributes_for_write();
|
||||
const bke::AttributeAccessor b = curves_b->geometry.wrap().attributes();
|
||||
const Array<int> index_map = create_id_index_map(a, b);
|
||||
mix_attributes(a,
|
||||
b,
|
||||
index_map,
|
||||
bke::AttrDomain::Point,
|
||||
factor,
|
||||
{"handle_type_left", "handle_type_right"});
|
||||
mix_attributes(
|
||||
a,
|
||||
b,
|
||||
index_map,
|
||||
bke::AttrDomain::Point,
|
||||
factor,
|
||||
{"curve_type", "nurbs_order", "knots_mode", "handle_type_left", "handle_type_right"});
|
||||
}
|
||||
}
|
||||
if (bke::Instances *instances_a = a.get_instances_for_write()) {
|
||||
@@ -193,7 +194,7 @@ bke::GeometrySet mix_geometries(bke::GeometrySet a, const bke::GeometrySet &b, c
|
||||
index_map,
|
||||
bke::AttrDomain::Instance,
|
||||
factor,
|
||||
{});
|
||||
{".reference_index"});
|
||||
}
|
||||
}
|
||||
return a;
|
||||
|
||||
Reference in New Issue
Block a user