diff options
author | Jesse Yurkovich <deadpin> | 2022-03-24 23:13:02 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2022-03-24 23:26:11 +0300 |
commit | 07846b31f34caa88244d192ee7d3aa6c057ac602 (patch) | |
tree | 974a462edcc14d115010cfe6f75d903f191bba65 /source/blender/makesdna/DNA_scene_types.h | |
parent | 3c4947cdaa04ac0afa69157a1788b9022b20905e (diff) |
Cleanup: Optimize viewport view data creation
Each time the user clicks the viewport 2 sets of engine views are
created. Each set is currently composed of 8 view objects, each of size
592 bytes.
Because space is not reserved in the vector that holds them, several
unnecessary re-allocation/copy cycles occur as the vector resizes and
the total allocation load is 8880 bytes. This happens twice.
Reduce to just the allocations necessary and with exactly 4736 bytes
allocated for each set
- Before: 8 allocations and 8 deallocations totaling 17760 bytes
- After: 2 allocations and 2 deallocations totaling 9472 bytes
Reviewed By: fclem, jbakker
Differential Revision: https://developer.blender.org/D13782
Diffstat (limited to 'source/blender/makesdna/DNA_scene_types.h')
0 files changed, 0 insertions, 0 deletions