Blender V4.3
dna_utils.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
9#pragma once
10
11#ifdef __cplusplus
12extern "C" {
13#endif
14
15struct GHash;
16struct MemArena;
17
31int DNA_member_array_num(const char *str);
32
34uint DNA_member_id_offset_start(const char *member_full);
42uint DNA_member_id_offset_end(const char *member_full_trimmed);
48uint DNA_member_id_strip_copy(char *member_id_dst, const char *member_full_src);
52uint DNA_member_id_strip(char *member);
59bool DNA_member_id_match(const char *member_id,
60 int member_id_len,
61 const char *member_full,
62 uint *r_member_full_offset);
72 const char *member_id_src,
73 int member_id_src_len,
74 const char *member_id_dst,
75 int member_id_dst_len,
76 const char *member_full_src,
77 int member_full_src_len,
78 uint member_full_src_offset_len);
79
91void DNA_alias_maps(enum eDNA_RenameDir version_dir,
92 struct GHash **r_type_map,
93 struct GHash **r_member_map);
94
98const char *DNA_struct_rename_legacy_hack_alias_from_static(const char *name);
99const char *DNA_struct_rename_legacy_hack_static_from_alias(const char *name);
100
101#ifdef __cplusplus
102}
103#endif
unsigned int uint
const char * DNA_struct_rename_legacy_hack_static_from_alias(const char *name)
Definition dna_utils.cc:293
const char * DNA_struct_rename_legacy_hack_alias_from_static(const char *name)
Definition dna_utils.cc:309
uint DNA_member_id_offset_end(const char *member_full_trimmed)
Definition dna_utils.cc:87
int DNA_member_array_num(const char *str)
Definition dna_utils.cc:29
bool DNA_member_id_match(const char *member_id, int member_id_len, const char *member_full, uint *r_member_full_offset)
Definition dna_utils.cc:116
uint DNA_member_id_offset_start(const char *member_full)
Definition dna_utils.cc:74
eDNA_RenameDir
Definition dna_utils.h:87
@ DNA_RENAME_ALIAS_FROM_STATIC
Definition dna_utils.h:89
@ DNA_RENAME_STATIC_FROM_ALIAS
Definition dna_utils.h:88
char * DNA_member_id_rename(struct MemArena *mem_arena, const char *member_id_src, int member_id_src_len, const char *member_id_dst, int member_id_dst_len, const char *member_full_src, int member_full_src_len, uint member_full_src_offset_len)
Definition dna_utils.cc:134
uint DNA_member_id_strip(char *member)
Definition dna_utils.cc:106
void DNA_alias_maps(enum eDNA_RenameDir version_dir, struct GHash **r_type_map, struct GHash **r_member_map)
Definition dna_utils.cc:193
uint DNA_member_id_strip_copy(char *member_id_dst, const char *member_full_src)
Definition dna_utils.cc:96
#define str(s)
static MemArena * mem_arena
Definition makesdna.cc:62