diff options
author | Hans Goudey <h.goudey@me.com> | 2021-12-10 19:42:28 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2021-12-10 19:42:28 +0300 |
commit | 5ca38fd612cdde15bf46a66f96993bad6a185706 (patch) | |
tree | a7d7cbc137d2e7b609d1ef5b745438929f35d757 /source/blender/blenkernel/intern/mesh.cc | |
parent | f886f293550c275160a340b0815c48f1c9e23220 (diff) |
Cleanup/Docs: Add comments to Mesh header, rearrange fields
Most of the fields in Mesh had no comments, or outdated misleading
comments. For example, "BMESH ONLY" referred to the BMesh project,
not the data structure. Given how much these structs are used, it should
save a lot of time to have proper comments.
I also rearranged the fields in mesh to have a more logical order. Now
the most important fields come first. In the process I was able to
remove 19 bytes of unnecessary padding (31->12). I just had to
change a `short` flag to `char`.
Differential Revision: https://developer.blender.org/D13454
Diffstat (limited to 'source/blender/blenkernel/intern/mesh.cc')
-rw-r--r-- | source/blender/blenkernel/intern/mesh.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/mesh.cc b/source/blender/blenkernel/intern/mesh.cc index 5f8d4ccb734..05aa9111fa3 100644 --- a/source/blender/blenkernel/intern/mesh.cc +++ b/source/blender/blenkernel/intern/mesh.cc @@ -1246,7 +1246,7 @@ void BKE_mesh_texspace_get(Mesh *me, float r_loc[3], float r_size[3]) } } -void BKE_mesh_texspace_get_reference(Mesh *me, short **r_texflag, float **r_loc, float **r_size) +void BKE_mesh_texspace_get_reference(Mesh *me, char **r_texflag, float **r_loc, float **r_size) { BKE_mesh_texspace_ensure(me); @@ -1264,7 +1264,7 @@ void BKE_mesh_texspace_get_reference(Mesh *me, short **r_texflag, float **r_loc, void BKE_mesh_texspace_copy_from_object(Mesh *me, Object *ob) { float *texloc, *texsize; - short *texflag; + char *texflag; if (BKE_object_obdata_texspace_get(ob, &texflag, &texloc, &texsize)) { me->texflag = *texflag; |