Geometry Nodes: Fix Assert in Duplicate Elements
The original assert did not take into account the offset size in the loop being -1. The tests were then run in non-debug mode, so while the mesh regressions still passed, the false positive asserts that happened were not caught. Differential Revision: https://developer.blender.org/D15136
This commit is contained in:
parent
34f94a02f3
commit
128aa7f3b0
|
@ -98,7 +98,7 @@ static void threaded_slice_fill(Span<int> offsets,
|
|||
MutableSpan<T> dst)
|
||||
{
|
||||
BLI_assert(offsets.last() == dst.size());
|
||||
BLI_assert(selection.size() == offsets.size());
|
||||
BLI_assert(selection.size() == offsets.size() - 1);
|
||||
threading::parallel_for(IndexRange(offsets.size() - 1), 512, [&](IndexRange range) {
|
||||
for (const int i : range) {
|
||||
dst.slice(range_for_offsets_index(offsets, i)).fill(src[selection[i]]);
|
||||
|
|
Loading…
Reference in New Issue