[Bf-committers] Sculpt Work

Joe Eagar joeedh at gmail.com
Mon Oct 19 14:06:11 CEST 2020


Greetings.  Recently I've found myself sucked into the sculpt code.  I
heard talk of removing DynTopo--a tool I absolutely could not live without,
and since the problems in the DynTopo code are partly my fault for not
properly documenting the design limitations of BMesh I thought I'd help fix
it.  While I'm at it I'm also going to finally fix some multires bugs I've
been meaning to fix for an embarrassing number of years.

For those who don't know I headed the BMesh refactor back in the day along
with Geoffrey Bantle who wrote the core BMesh api.  The two of us never
intended for BMesh to be used for anything like high-res sculpting, but
unfortunately we never actually wrote that down anywhere in the codebase.
This has led to a bit of a mess in the DynTopo code.

Anyway, as I see it DynTopo needs two things:
* Rip out BMesh.  This has actually mostly happened already; DynTopo
strictly forces faces to be triangles and reuses very little of the BMesh
API opting for its own implementation of topology operations.  I've already
done this in a branch.
* Refactor PBVH/sculpt code to be more maintainable, given the presence of
DynTopo.  I get the impression that this is a major concern for the sculpt
dev team.  I plan to make a few proposals here.

I'm also going to try and profile CPU cache and branch prediction misses,
since this seems to be a problem.  Unfortunately I wasn't able to get
blender to run in valgrind in a VM, but luckily I have a Linux machine in
the house I can set up for the task.

Cheers,
Joe Eagar


More information about the Bf-committers mailing list