diff options
author | Campbell Barton <campbell@blender.org> | 2022-10-03 03:15:45 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-10-03 03:19:15 +0300 |
commit | d4d40f3b69d8d9d1cd65839d8b577010b708112d (patch) | |
tree | 4dc52d3b92ce8ec9d0ac6d57e2caa5c1e29c0c57 /source/blender | |
parent | d3ba8826b0e96c8c5293ba4a2c5d1bd42a8c6ccb (diff) |
DNA: reduce size of Base struct
Re-order members and remove pad members,
reducing it's size by 24 bytes on 64 bit systems.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/makesdna/DNA_layer_types.h | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/source/blender/makesdna/DNA_layer_types.h b/source/blender/makesdna/DNA_layer_types.h index 63bc379c27a..827e07725a1 100644 --- a/source/blender/makesdna/DNA_layer_types.h +++ b/source/blender/makesdna/DNA_layer_types.h @@ -71,26 +71,23 @@ typedef enum eViewLayerCryptomatteFlags { typedef struct Base { struct Base *next, *prev; - /* Flags which are based on the collections flags evaluation, does not - * include flags from object's restrictions. */ - short flag_from_collection; + struct Object *object; + + /* Pointer to an original base. Is initialized for evaluated view layer. + * NOTE: Only allowed to be accessed from within active dependency graph. */ + struct Base *base_orig; + unsigned int lay DNA_DEPRECATED; /* Final flags, including both accumulated collection flags and object's * restriction flags. */ short flag; - + /* Flags which are based on the collections flags evaluation, does not + * include flags from object's restrictions. */ + short flag_from_collection; + short flag_legacy; unsigned short local_view_bits; - char _pad1[10]; - struct Object *object; - unsigned int lay DNA_DEPRECATED; - int flag_legacy; unsigned short local_collections_bits; - short _pad2[3]; - - /* Pointer to an original base. Is initialized for evaluated view layer. - * NOTE: Only allowed to be accessed from within active dependency graph. */ - struct Base *base_orig; - void *_pad; + char _pad1[2]; } Base; typedef struct ViewLayerEngineData { |