Page MenuHome

DNA: use better type for SDNA->structs
ClosedPublic

Authored by Jacques Lucke (JacquesLucke) on Sep 17 2020, 5:01 PM.

Details

Summary

The data layout remains exactly the same.
This change just gives all the elements in SDNA->structs names. This reduces the wtf/min significantly when reading dna_genfile.c.

There are quite a few more variable names that can be improved, but that can be done in a separate cleanup commit if necessary.

Diff Detail

Repository
rB Blender

Event Timeline

Jacques Lucke (JacquesLucke) requested review of this revision.Sep 17 2020, 5:01 PM
Jacques Lucke (JacquesLucke) created this revision.
  • Merge branch 'master' into dna-structs-refactor
  • docs
  • Merge branch 'master' into dna-structs-refactor
Campbell Barton (campbellbarton) added inline comments.
source/blender/makesdna/DNA_sdna_types.h
29

This should note that unlike other DNA types, these can't change as size, it's only for convenience.

31–33

any reason not to use int16_t ?

This revision is now accepted and ready to land.Tue, Sep 29, 7:01 AM
source/blender/makesdna/DNA_sdna_types.h
31–33

I did not want to change types in this commit. Changing short to int16_t everywhere, can be done separately.