Page MenuHome

Sculpt: Use vertices instead of faces to limit the grids in each PBVH node
ClosedPublic

Authored by Pablo Dobarro (pablodp606) on Aug 3 2020, 6:01 PM.

Details

Summary

This uses the vertices per grid instead of quads to set the limit of
grids per PBVH Node. This should create more leaf nodes in lower
subdivisions levels where the duplicates count is high, producing more
uniform performance across different levels.

Before:

After:

Diff Detail

Repository
rB Blender
Branch
pbvh-grid-vertex-count (branched from master)
Build Status
Buildable 9318
Build 9318: arc lint + arc unit

Event Timeline

Pablo Dobarro (pablodp606) requested review of this revision.Aug 3 2020, 6:01 PM

Even after this patch it still lags way more than it should for that vertex count and that brush size, so maybe @Julien Kaspar (JulienKaspar) could test this with more files to see if it actually fixes something.

@Pablo Dobarro (pablodp606) I tested this patch on the jacket file and it has a significant performance boost for me. On level 3 it still lags when the stroke is too fast and too long but on level 1 this patch has removed almost all lag I was experiencing.
Even on other project files it has a very noticeable performance boost and removes all lag from level 1 sculpting.

This revision is now accepted and ready to land.Aug 5 2020, 12:35 PM