[Bf-committers] Sculpt Smooth Tool Patch

Jason Wilkins jason.a.wilkins at gmail.com
Sat May 12 07:51:39 CEST 2012


In another project I learned that malloc can be a serious bottleneck
inside an inner loop, so when I saw that being done with the sculpt
smooth tool I moved the memory allocation outside the main stroke loop
and to the beginning of the stroke.

It could probably be made even more efficient by only allocating a
temp mask or temp coordinates, but that would complicate the code and
it has already gone from O(n) to O(1).

More information about the Bf-committers mailing list