Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/makesdna/DNA_sdna_types.h')
-rw-r--r--source/blender/makesdna/DNA_sdna_types.h34
1 files changed, 26 insertions, 8 deletions
diff --git a/source/blender/makesdna/DNA_sdna_types.h b/source/blender/makesdna/DNA_sdna_types.h
index cfb65860b8e..3af12ae791f 100644
--- a/source/blender/makesdna/DNA_sdna_types.h
+++ b/source/blender/makesdna/DNA_sdna_types.h
@@ -26,6 +26,30 @@ struct MemArena;
#
#
+typedef struct SDNA_StructMember {
+ /** This struct must not change, it's only a convenience view for raw data stored in SDNA. */
+
+ /** An index into SDNA->types. */
+ short type;
+ /** An index into SDNA->names. */
+ short name;
+} SDNA_StructMember;
+
+#
+#
+typedef struct SDNA_Struct {
+ /** This struct must not change, it's only a convenience view for raw data stored in SDNA. */
+
+ /** An index into SDNA->types. */
+ short type;
+ /** The amount of members in this struct. */
+ short members_len;
+ /** "Flexible array member" that contains information about all members of this struct. */
+ SDNA_StructMember members[];
+} SDNA_Struct;
+
+#
+#
typedef struct SDNA {
/** Full copy of 'encoded' data (when data_alloc is set, otherwise borrowed). */
const char *data;
@@ -51,14 +75,8 @@ typedef struct SDNA {
/** Type lengths. */
short *types_size;
- /**
- * sp = structs[a] is the address of a struct definition
- * sp[0] is struct type number, sp[1] amount of members
- *
- * (sp[2], sp[3]), (sp[4], sp[5]), .. are the member
- * type and name numbers respectively.
- */
- short **structs;
+ /** Information about structs and their members. */
+ SDNA_Struct **structs;
/** Number of struct types. */
int structs_len;