diff options
author | Hans Goudey <h.goudey@me.com> | 2022-09-23 16:23:35 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2022-09-23 16:23:35 +0300 |
commit | 0d7d8c73cf5c5c5f05c6a56951e4e5cd24871c12 (patch) | |
tree | eb4462fdebcef4afca161d1257ecb7a78d298cec /source/blender/geometry | |
parent | 060a5341419412fd7996cf99a56db1f581a4c30c (diff) |
Mesh: Use cached looptris in draw cache extraction
The mesh's triangulation cache is often created for other operations
besides the drawing code, but during the mesh draw cache extraction
it is recalculated on every single time. It is simpler and faster to use
the existing MLoopTri array. It can also save memory if the cache
already exists by avoiding allocating a duplicate array. For a 4 million
face quad mesh, that is already 128 MB.
Also use face normals for mesh triangulation if they aren't dirty,
which should provide a general speedup when they're both necessary.
Recently 54182e4925de made this more reliable, since the triangulation
cache is invalidated properly when the mesh is deformed.
Fixes T98073
Differential Revision: https://developer.blender.org/D15550
Diffstat (limited to 'source/blender/geometry')
0 files changed, 0 insertions, 0 deletions