Page MenuHome

Geometry Nodes: Fix attribute propagation in Delete Geometry node.
ClosedPublic

Authored by Jacques Lucke (JacquesLucke) on Nov 23 2021, 4:31 PM.

Details

Summary

Attribute propagation only worked in the "All" mode, but not in the others.
In the "All" mode it actually still depends on CustomData_copy_data from the mask modifier it seems.

Face attributes were propagated incorrectly.
Face Corner attributes were not propagated at all.

Old:

New:

Diff Detail

Repository
rB Blender

Event Timeline

Jacques Lucke (JacquesLucke) requested review of this revision.Nov 23 2021, 4:31 PM
Jacques Lucke (JacquesLucke) created this revision.
source/blender/nodes/geometry/nodes/node_geo_delete_geometry.cc
206

Maybe note that a valid optimization would be checking whether there are any face corner domain attributes to copy? (Or do the optimization I guess)

1136

Won't this allocate a new int64_t vector? Could probably just change the original vector to int64_t instead?

source/blender/nodes/geometry/nodes/node_geo_delete_geometry.cc
206

Won't do the optimization just yet. The same optimization could be done for the other domains, but that shouldn't be part of 3.0 anymore.

1136

It does. I think think it would be more correct not to use IndexMask but Span<int> here. But fixing it either way requires changes to quite a few more places in this file that I'd rather avoid right now. The performance overhead probably isn't too bad. It's just copying one integer per polygon in the output mesh.

Okay, limiting changes in 3.0 sounds totally reasonable. Do you mind mentioning those things in the commit or comments though?

This revision is now accepted and ready to land.Nov 23 2021, 5:42 PM