Merge branch 'blender-v4.1-release'

This commit is contained in:
Philipp Oeser
2024-02-08 14:49:57 +01:00
2 changed files with 5 additions and 3 deletions

View File

@@ -260,7 +260,7 @@ struct PuffOperationExecutor {
brush_, dist_to_brush_cu, brush_radius_cu);
math::max_inplace(max_weight, radius_falloff);
}
r_curve_weights[curve_i] = max_weight;
math::max_inplace(r_curve_weights[curve_i], max_weight);
});
}

View File

@@ -595,7 +595,8 @@ static bool restore_color(Object *ob, Node &unode, MutableSpan<bool> modified_ve
/* NOTE: even with loop colors we still store derived
* vertex colors for original data lookup. */
if (!unode.col.is_empty() && unode.loop_col.is_empty()) {
BKE_pbvh_swap_colors(ss->pbvh, unode.vert_indices, unode.col);
BKE_pbvh_swap_colors(
ss->pbvh, unode.vert_indices.as_span().take_front(unode.unique_verts_num), unode.col);
modified = true;
}
@@ -1404,7 +1405,8 @@ static void store_color(Object *ob, Node *unode)
/* NOTE: even with loop colors we still store (derived)
* vertex colors for original data lookup. */
BKE_pbvh_store_colors_vertex(ss->pbvh, unode->vert_indices, unode->col);
BKE_pbvh_store_colors_vertex(
ss->pbvh, unode->vert_indices.as_span().take_front(unode->unique_verts_num), unode->col);
if (!unode->loop_col.is_empty() && !unode->corner_indices.is_empty()) {
BKE_pbvh_store_colors(ss->pbvh, unode->corner_indices, unode->loop_col);