34 {
ID_AC,
"ACTION", ICON_ACTION,
"Action",
""},
35 {
ID_AR,
"ARMATURE", ICON_ARMATURE_DATA,
"Armature",
""},
36 {
ID_BR,
"BRUSH", ICON_BRUSH_DATA,
"Brush",
""},
37 {
ID_CF,
"CACHEFILE", ICON_FILE,
"Cache File",
""},
38 {
ID_CA,
"CAMERA", ICON_CAMERA_DATA,
"Camera",
""},
39 {
ID_GR,
"COLLECTION", ICON_OUTLINER_COLLECTION,
"Collection",
""},
41 {
ID_CV,
"CURVES", ICON_CURVES_DATA,
"Curves",
""},
42 {
ID_VF,
"FONT", ICON_FONT_DATA,
"Font",
""},
43 {
ID_GD_LEGACY,
"GREASEPENCIL", ICON_GREASEPENCIL,
"Grease Pencil",
""},
44 {
ID_GP,
"GREASEPENCIL_V3", ICON_GREASEPENCIL,
"Grease Pencil v3",
""},
45 {
ID_IM,
"IMAGE", ICON_IMAGE_DATA,
"Image",
""},
46 {
ID_KE,
"KEY", ICON_SHAPEKEY_DATA,
"Key",
""},
47 {
ID_LT,
"LATTICE", ICON_LATTICE_DATA,
"Lattice",
""},
48 {
ID_LI,
"LIBRARY", ICON_LIBRARY_DATA_DIRECT,
"Library",
""},
49 {
ID_LA,
"LIGHT", ICON_LIGHT_DATA,
"Light",
""},
50 {
ID_LP,
"LIGHT_PROBE", ICON_LIGHTPROBE_SPHERE,
"Light Probe",
""},
51 {
ID_LS,
"LINESTYLE", ICON_LINE_DATA,
"Line Style",
""},
52 {
ID_MSK,
"MASK", ICON_MOD_MASK,
"Mask",
""},
53 {
ID_MA,
"MATERIAL", ICON_MATERIAL_DATA,
"Material",
""},
54 {
ID_ME,
"MESH", ICON_MESH_DATA,
"Mesh",
""},
55 {
ID_MB,
"META", ICON_META_DATA,
"Metaball",
""},
56 {
ID_MC,
"MOVIECLIP", ICON_TRACKER,
"Movie Clip",
""},
57 {
ID_NT,
"NODETREE", ICON_NODETREE,
"Node Tree",
""},
58 {
ID_OB,
"OBJECT", ICON_OBJECT_DATA,
"Object",
""},
59 {
ID_PC,
"PAINTCURVE", ICON_CURVE_BEZCURVE,
"Paint Curve",
""},
60 {
ID_PAL,
"PALETTE", ICON_COLOR,
"Palette",
""},
61 {
ID_PA,
"PARTICLE", ICON_PARTICLE_DATA,
"Particle",
""},
62 {
ID_PT,
"POINTCLOUD", ICON_POINTCLOUD_DATA,
"Point Cloud",
""},
63 {
ID_SCE,
"SCENE", ICON_SCENE_DATA,
"Scene",
""},
64 {
ID_SCR,
"SCREEN", ICON_WORKSPACE,
"Screen",
""},
65 {
ID_SO,
"SOUND", ICON_SOUND,
"Sound",
""},
66 {
ID_SPK,
"SPEAKER", ICON_SPEAKER,
"Speaker",
""},
67 {
ID_TXT,
"TEXT", ICON_TEXT,
"Text",
""},
68 {
ID_TE,
"TEXTURE", ICON_TEXTURE_DATA,
"Texture",
""},
69 {
ID_VO,
"VOLUME", ICON_VOLUME_DATA,
"Volume",
""},
70 {
ID_WM,
"WINDOWMANAGER", ICON_WINDOW,
"Window Manager",
""},
71 {
ID_WS,
"WORKSPACE", ICON_WORKSPACE,
"Workspace",
""},
72 {
ID_WO,
"WORLD", ICON_WORLD_DATA,
"World",
""},
73 {0,
nullptr, 0,
nullptr,
nullptr},
81 "Does nothing, prevents adding actual overrides (NOT USED)"},
86 "Replace value of reference by overriding one"},
91 "Stores and apply difference between reference and local value (NOT USED)"},
96 "Stores and apply difference between reference and local value (NOT USED)"},
101 "Stores and apply multiplication factor between reference and local value (NOT USED)"},
106 "Insert a new item into collection after the one referenced in "
107 "subitem_reference_name/_id or _index"},
112 "Insert a new item into collection before the one referenced in "
113 "subitem_reference_name/_id or _index (NOT USED)"},
118 "Custom operation, specific to a RNA property, and handled through dedicated callbacks (used "
119 "in specific cases, e.g. to handle data not actually exposed in RNA)"},
120 {0,
nullptr, 0,
nullptr,
nullptr},
128 {
FILTER_ID_AC,
"filter_action", ICON_ACTION,
"Actions",
"Show Action data-blocks"},
133 "Show Armature data-blocks"},
134 {
FILTER_ID_BR,
"filter_brush", ICON_BRUSH_DATA,
"Brushes",
"Show Brushes data-blocks"},
135 {
FILTER_ID_CA,
"filter_camera", ICON_CAMERA_DATA,
"Cameras",
"Show Camera data-blocks"},
136 {
FILTER_ID_CF,
"filter_cachefile", ICON_FILE,
"Cache Files",
"Show Cache File data-blocks"},
137 {
FILTER_ID_CU_LEGACY,
"filter_curve", ICON_CURVE_DATA,
"Curves",
"Show Curve data-blocks"},
139 "filter_annotations",
140 ICON_OUTLINER_DATA_GREASEPENCIL,
142 "Show Annotation data-blocks"},
144 "filter_grease_pencil",
147 "Show Grease Pencil data-blocks"},
148 {
FILTER_ID_GR,
"filter_group", ICON_GROUP,
"Collections",
"Show Collection data-blocks"},
153 "Show/hide Curves data-blocks"},
154 {
FILTER_ID_IM,
"filter_image", ICON_IMAGE_DATA,
"Images",
"Show Image data-blocks"},
155 {
FILTER_ID_LA,
"filter_light", ICON_LIGHT_DATA,
"Lights",
"Show Light data-blocks"},
157 "filter_light_probe",
158 ICON_OUTLINER_DATA_LIGHTPROBE,
160 "Show Light Probe data-blocks"},
164 "Freestyle Linestyles",
165 "Show Freestyle's Line Style data-blocks"},
166 {
FILTER_ID_LT,
"filter_lattice", ICON_LATTICE_DATA,
"Lattices",
"Show Lattice data-blocks"},
171 "Show Material data-blocks"},
172 {
FILTER_ID_MB,
"filter_metaball", ICON_META_DATA,
"Metaballs",
"Show Metaball data-blocks"},
177 "Show Movie Clip data-blocks"},
178 {
FILTER_ID_ME,
"filter_mesh", ICON_MESH_DATA,
"Meshes",
"Show Mesh data-blocks"},
179 {
FILTER_ID_MSK,
"filter_mask", ICON_MOD_MASK,
"Masks",
"Show Mask data-blocks"},
180 {
FILTER_ID_NT,
"filter_node_tree", ICON_NODETREE,
"Node Trees",
"Show Node Tree data-blocks"},
181 {
FILTER_ID_OB,
"filter_object", ICON_OBJECT_DATA,
"Objects",
"Show Object data-blocks"},
183 "filter_particle_settings",
185 "Particles Settings",
186 "Show Particle Settings data-blocks"},
187 {
FILTER_ID_PAL,
"filter_palette", ICON_COLOR,
"Palettes",
"Show Palette data-blocks"},
189 "filter_paint_curve",
192 "Show Paint Curve data-blocks"},
195 ICON_POINTCLOUD_DATA,
197 "Show/hide Point Cloud data-blocks"},
198 {
FILTER_ID_SCE,
"filter_scene", ICON_SCENE_DATA,
"Scenes",
"Show Scene data-blocks"},
199 {
FILTER_ID_SPK,
"filter_speaker", ICON_SPEAKER,
"Speakers",
"Show Speaker data-blocks"},
200 {
FILTER_ID_SO,
"filter_sound", ICON_SOUND,
"Sounds",
"Show Sound data-blocks"},
201 {
FILTER_ID_TE,
"filter_texture", ICON_TEXTURE_DATA,
"Textures",
"Show Texture data-blocks"},
202 {
FILTER_ID_TXT,
"filter_text", ICON_TEXT,
"Texts",
"Show Text data-blocks"},
203 {
FILTER_ID_VF,
"filter_font", ICON_FONT_DATA,
"Fonts",
"Show Font data-blocks"},
204 {
FILTER_ID_VO,
"filter_volume", ICON_VOLUME_DATA,
"Volumes",
"Show/hide Volume data-blocks"},
205 {
FILTER_ID_WO,
"filter_world", ICON_WORLD_DATA,
"Worlds",
"Show World data-blocks"},
210 "Show workspace data-blocks"},
211 {0,
nullptr, 0,
nullptr,
nullptr},
256void rna_ID_override_library_property_operation_refname_get(
PointerRNA *ptr,
char *value)
260 strcpy(value, (opop->subitem_reference_name ==
nullptr) ?
"" : opop->subitem_reference_name);
263int rna_ID_override_library_property_operation_refname_length(
PointerRNA *ptr)
267 return (opop->subitem_reference_name ==
nullptr) ? 0 : strlen(opop->subitem_reference_name);
270void rna_ID_override_library_property_operation_locname_get(
PointerRNA *ptr,
char *value)
274 strcpy(value, (opop->subitem_local_name ==
nullptr) ?
"" : opop->subitem_local_name);
277int rna_ID_override_library_property_operation_locname_length(
PointerRNA *ptr)
281 return (opop->subitem_local_name ==
nullptr) ? 0 : strlen(opop->subitem_local_name);
284void rna_ID_override_library_property_operation_label_get(
PointerRNA *ptr,
char *value)
288 strcpy(value, (opop->label ==
nullptr) ?
"" : opop->label);
291int rna_ID_override_library_property_operation_label_length(
PointerRNA *ptr)
295 return (opop->label ==
nullptr) ? 0 : strlen(opop->label);
298void rna_ID_override_library_property_operation_tooltip_get(
PointerRNA *ptr,
char *value)
302 strcpy(value, (opop->tooltip ==
nullptr) ?
"" : opop->tooltip);
305int rna_ID_override_library_property_operation_tooltip_length(
PointerRNA *ptr)
309 return (opop->tooltip ==
nullptr) ? 0 : strlen(opop->tooltip);
315 ID *
id =
static_cast<ID *
>(ptr->data);
316 strcpy(value,
id->name + 2);
321 ID *
id =
static_cast<ID *
>(ptr->data);
322 return strlen(
id->name + 2);
325static int rna_ID_rename(
ID *self,
Main *bmain,
const char *new_name,
const int mode)
328 return int(
result.action);
333 ID *
id =
static_cast<ID *
>(ptr->data);
338static int rna_ID_name_editable(
const PointerRNA *ptr,
const char **r_info)
340 ID *
id =
static_cast<ID *
>(ptr->data);
348 *r_info =
N_(
"Packed data-blocks cannot be renamed");
351 *r_info =
N_(
"Linked data-blocks cannot be renamed");
361 *r_info =
N_(
"Built-in fonts cannot be renamed");
368 *r_info =
N_(
"Data-blocks not in global Main data-base cannot be renamed");
376void rna_ID_name_full_get(
PointerRNA *ptr,
char *value)
378 ID *
id =
static_cast<ID *
>(ptr->data);
384 ID *
id =
static_cast<ID *
>(ptr->data);
392 ID *
id =
static_cast<ID *
>(ptr->data);
396static bool rna_ID_is_evaluated_get(
PointerRNA *ptr)
398 ID *
id =
static_cast<ID *
>(ptr->data);
405 ID *
id =
static_cast<ID *
>(ptr->data);
413 if (base_type ==
nullptr) [[unlikely]] {
416 if (base_type == RNA_Action) {
419 if (base_type == RNA_Armature) {
422 if (base_type == RNA_Brush) {
425 if (base_type == RNA_CacheFile) {
428 if (base_type == RNA_Camera) {
431 if (base_type == RNA_Curve) {
434 if (base_type == RNA_Annotation) {
437 if (base_type == RNA_GreasePencil) {
440 if (base_type == RNA_Collection) {
443 if (base_type == RNA_Image) {
446 if (base_type == RNA_Key) {
449 if (base_type == RNA_Light) {
452 if (base_type == RNA_Library) {
455 if (base_type == RNA_FreestyleLineStyle) {
458 if (base_type == RNA_Curves) {
461 if (base_type == RNA_Lattice) {
464 if (base_type == RNA_Material) {
467 if (base_type == RNA_MetaBall) {
470 if (base_type == RNA_MovieClip) {
473 if (base_type == RNA_Mesh) {
476 if (base_type == RNA_Mask) {
479 if (base_type == RNA_NodeTree) {
482 if (base_type == RNA_Object) {
485 if (base_type == RNA_ParticleSettings) {
488 if (base_type == RNA_Palette) {
491 if (base_type == RNA_PaintCurve) {
494 if (base_type == RNA_PointCloud) {
497 if (base_type == RNA_LightProbe) {
500 if (base_type == RNA_Scene) {
503 if (base_type == RNA_Screen) {
506 if (base_type == RNA_Sound) {
509 if (base_type == RNA_Speaker) {
512 if (base_type == RNA_Texture) {
515 if (base_type == RNA_Text) {
518 if (base_type == RNA_VectorFont) {
521 if (base_type == RNA_Volume) {
524 if (base_type == RNA_WorkSpace) {
527 if (base_type == RNA_World) {
530 if (base_type == RNA_WindowManager) {
551 return RNA_CacheFile;
555 return RNA_Annotation;
557 return RNA_GreasePencil;
559 return RNA_Collection;
571 return RNA_FreestyleLineStyle;
579 return RNA_MovieClip;
589 return RNA_ParticleSettings;
593 return RNA_PaintCurve;
595 return RNA_PointCloud;
597 return RNA_LightProbe;
611 return RNA_VectorFont;
615 return RNA_WindowManager;
619 return RNA_WorkSpace;
627 ID *
id =
static_cast<ID *
>(ptr->data);
634 ID *
id =
static_cast<ID *
>(ptr->data);
640 ID *
id =
static_cast<ID *
>(ptr->data);
644int rna_ID_is_runtime_editable(
const PointerRNA *ptr,
const char **r_info)
646 ID *
id =
static_cast<ID *
>(ptr->data);
650 "Cannot edit 'runtime' status of non-blendfile data-blocks, as they are by definition "
660 ID *
id =
static_cast<ID *
>(ptr->data);
671 ID *
id =
static_cast<ID *
>(ptr->data);
677 ID *
id =
static_cast<ID *
>(ptr->data);
687void rna_ID_extra_user_set(
PointerRNA *ptr,
bool value)
689 ID *
id =
static_cast<ID *
>(ptr->data);
701 return reinterpret_cast<IDProperty **
>(&ptr->data);
719 const char *identifier,
728 if (validate(&dummy_ptr,
data,
nullptr) != 0) {
739 "Registering id property class: '%s' is too long, maximum length is %d",
753static ID *rna_ID_evaluated_get(
ID *
id, Depsgraph *depsgraph)
758static ID *rna_ID_copy(
ID *
id,
Main *bmain)
762 if (newid !=
nullptr) {
772static void rna_ID_asset_mark(
ID *
id)
780static void rna_ID_asset_generate_preview(
ID *
id,
bContext *
C)
788static void rna_ID_asset_clear(
ID *
id)
798 ID *destination =
static_cast<ID *
>(ptr->data);
802 if (destination->asset_data ==
nullptr) {
805 "Asset data can only be assigned to assets. Use asset_mark() to mark as an asset.");
810 if (asset_data ==
nullptr) {
820 reports,
RPT_ERROR,
"'%s' is of a type that cannot be an asset", destination->name + 2);
828static ID *rna_ID_override_create(
ID *
id,
Main *bmain,
bool remap_local_usages)
834 if (remap_local_usages) {
838 ID *local_id =
nullptr;
849 if (remap_local_usages) {
859static ID *rna_ID_override_hierarchy_create(
ID *
id,
863 ID *id_instance_hint,
864 bool do_fully_editable)
872 ID *id_root_override =
nullptr;
895 return id_root_override;
898static void rna_ID_override_library_operations_update(
ID *
id,
918static void rna_ID_override_library_reset(
ID *
id,
923 bool set_system_override)
940static void rna_ID_override_library_destroy(
ID *
id,
962static bool rna_ID_override_library_resync(
ID *
id,
969 bool do_hierarchy_enforce,
970 bool do_whole_hierarchy)
974 if (!override_library->hierarchy_root ||
980 "Data-block '%s' is not a library override, or not part of a library override hierarchy",
985 ID *id_root = do_whole_hierarchy ? override_library->hierarchy_root :
id;
993 override_resync_residual_storage,
994 do_hierarchy_enforce,
1006 override_library,
rna_path, &created);
1009 BKE_report(reports,
RPT_DEBUG,
"No new override property created, property already exists");
1016static void rna_ID_override_library_properties_remove(
IDOverrideLibrary *override_library,
1020 if (
BLI_findindex(&override_library->properties, override_property) == -1) {
1035 const char *subitem_refname,
1036 const char *subitem_locname,
1039 int subitem_refindex,
1040 int subitem_locindex)
1049 use_id ? std::optional(subitem_refid) : std::nullopt,
1050 use_id ? std::optional(subitem_locid) : std::nullopt,
1057 BKE_report(reports,
RPT_DEBUG,
"No new override operation created, operation already exists");
1064static void rna_ID_override_library_property_operations_remove(
1069 if (
BLI_findindex(&override_property->operations, override_operation) == -1) {
1079static void rna_ID_deephash_get(
PointerRNA *ptr,
char *value)
1081 ID *
id = ptr->data_as<
ID>();
1082 memcpy(value,
id->deep_hash.data,
sizeof(
id->deep_hash.data));
1083 value[
sizeof(
id->deep_hash.data)] =
'\0';
1086static int rna_ID_deephash_len(
PointerRNA *ptr)
1088 ID *
id = ptr->data_as<
ID>();
1089 return sizeof(
id->deep_hash.data);
1092static void rna_ID_update_tag(
ID *
id,
Main *bmain,
ReportList *reports,
int flag)
1097 Curve *cu = ob->data;
1098 freedisplist(&cu->disp);
1110 switch (
GS(
id->name)) {
1121 allow_flag = OB_RECALC_ALL | PSYS_RECALC;
1133 if (flag & ~allow_flag) {
1137 allow_flag ?
N_(
"%s is not compatible with the specified 'refresh' options") :
1138 N_(
"%s is not compatible with any 'refresh' options"),
1147static void rna_ID_user_clear(
ID *
id)
1153static void rna_ID_user_remap(
ID *
id,
Main *bmain,
ID *new_id)
1155 if ((
GS(
id->name) ==
GS(new_id->name)) && (
id != new_id)) {
1164static ID *rna_ID_make_local(
1165 ID *self,
Main *bmain,
bool ,
bool clear_liboverride,
bool clear_asset_data)
1169 if (clear_asset_data) {
1189static AnimData *rna_ID_animation_data_create(
ID *
id,
Main *bmain)
1196static void rna_ID_animation_data_free(
ID *
id,
Main *bmain)
1205 ID *
id =
static_cast<ID *
>(ptr->data);
1217static int rna_IDPArray_length(
PointerRNA *ptr)
1225 ID *
id = ptr->owner_id;
1227 Material *mat_id = id_cast<Material *>(assign_ptr->owner_id);
1228 if (totcol && (key >= 0 && key < *totcol)) {
1239static void rna_IDMaterials_append_id(
ID *
id,
Main *bmain,
Material *ma)
1251 const short totcol_orig = *totcol;
1253 index_i += (*totcol);
1256 if ((index_i < 0) || (index_i >= (*totcol))) {
1263 if (*totcol == totcol_orig) {
1275static void rna_IDMaterials_clear_id(
ID *
id,
Main *bmain)
1284static void rna_Library_filepath_set(
PointerRNA *ptr,
const char *value)
1295 ID *
id = ptr->owner_id;
1298 if (
id !=
nullptr) {
1322 ID *
id = ptr->owner_id;
1325 if (
id !=
nullptr) {
1331 values[0] = prv_img->w[
size];
1332 values[1] = prv_img->h[
size];
1337 ID *
id = ptr->owner_id;
1340 if (
id !=
nullptr) {
1346 if (values[0] && values[1]) {
1350 prv_img->w[
size] = values[0];
1351 prv_img->h[
size] = values[1];
1357static int rna_ImagePreview_pixels_get_length(
const PointerRNA *ptr,
1361 ID *
id = ptr->owner_id;
1364 if (
id !=
nullptr) {
1377 ID *
id = ptr->owner_id;
1380 if (
id !=
nullptr) {
1386 memcpy(values, prv_img->rect[size], prv_img->w[size] * prv_img->h[size] *
sizeof(
uint));
1389static void rna_ImagePreview_pixels_set(
PointerRNA *ptr,
const int *values,
enum eIconSizes size)
1391 ID *
id = ptr->owner_id;
1394 if (
id !=
nullptr) {
1398 memcpy(prv_img->rect[size], values, prv_img->w[size] * prv_img->h[size] *
sizeof(
uint));
1402static int rna_ImagePreview_pixels_float_get_length(
const PointerRNA *ptr,
1406 ID *
id = ptr->owner_id;
1411 if (
id !=
nullptr) {
1422static void rna_ImagePreview_pixels_float_get(
PointerRNA *ptr,
float *values,
enum eIconSizes size)
1424 ID *
id = ptr->owner_id;
1428 const size_t len = prv_img->w[
size] * prv_img->h[
size] * 4;
1433 if (
id !=
nullptr) {
1439 for (i = 0; i <
len; i++) {
1440 values[i] =
data[i] * (1.0f / 255.0f);
1444static void rna_ImagePreview_pixels_float_set(
PointerRNA *ptr,
1445 const float *values,
1448 ID *
id = ptr->owner_id;
1452 const size_t len = prv_img->w[
size] * prv_img->h[
size] * 4;
1457 if (
id !=
nullptr) {
1461 for (i = 0; i <
len; i++) {
1467static void rna_ImagePreview_is_image_custom_set(
PointerRNA *ptr,
bool value)
1472static void rna_ImagePreview_image_size_get(
PointerRNA *ptr,
int *values)
1477static void rna_ImagePreview_image_size_set(
PointerRNA *ptr,
const int *values)
1482static int rna_ImagePreview_image_pixels_get_length(
const PointerRNA *ptr,
1488static void rna_ImagePreview_image_pixels_get(
PointerRNA *ptr,
int *values)
1493static void rna_ImagePreview_image_pixels_set(
PointerRNA *ptr,
const int *values)
1498static int rna_ImagePreview_image_pixels_float_get_length(
const PointerRNA *ptr,
1504static void rna_ImagePreview_image_pixels_float_get(
PointerRNA *ptr,
float *values)
1509static void rna_ImagePreview_image_pixels_float_set(
PointerRNA *ptr,
const float *values)
1514static void rna_ImagePreview_is_icon_custom_set(
PointerRNA *ptr,
bool value)
1519static void rna_ImagePreview_icon_size_get(
PointerRNA *ptr,
int *values)
1524static void rna_ImagePreview_icon_size_set(
PointerRNA *ptr,
const int *values)
1529static int rna_ImagePreview_icon_pixels_get_length(
const PointerRNA *ptr,
1535static void rna_ImagePreview_icon_pixels_get(
PointerRNA *ptr,
int *values)
1540static void rna_ImagePreview_icon_pixels_set(
PointerRNA *ptr,
const int *values)
1545static int rna_ImagePreview_icon_pixels_float_get_length(
const PointerRNA *ptr,
1551static void rna_ImagePreview_icon_pixels_float_get(
PointerRNA *ptr,
float *values)
1556static void rna_ImagePreview_icon_pixels_float_set(
PointerRNA *ptr,
const float *values)
1561static int rna_ImagePreview_icon_id_get(
PointerRNA *ptr)
1567static void rna_ImagePreview_icon_reload(
PreviewImage *prv)
1579 ID *
id =
static_cast<ID *
>(ptr->data);
1587 if (ptr ==
nullptr) {
1590 return reinterpret_cast<IDProperty **
>(&ptr->data);
1593static void rna_Library_version_get(
PointerRNA *ptr,
int *value)
1597 value[1] = lib->runtime->versionfile % 100;
1598 value[2] = lib->runtime->subversionfile;
1603 iter->parent = *ptr;
1607 iter->internal.custom = archive_libraries_iter;
1609 iter->valid = archive_libraries_iter != lib->runtime->archived_libraries.end();
1615 Library **archive_libraries_iter =
static_cast<Library **
>(iter->internal.custom);
1617 archive_libraries_iter++;
1618 iter->internal.custom = archive_libraries_iter;
1625 Library **archive_libraries_iter =
static_cast<Library **
>(iter->internal.custom);
1629static int rna_Library_archive_libraries_length(
PointerRNA *ptr)
1632 return int(lib->runtime->archived_libraries.size());
1635static bool rna_Library_archive_libraries_lookupint(
PointerRNA *ptr,
int key,
PointerRNA *r_ptr)
1638 if (key < 0 || key >= lib->runtime->archived_libraries.size()) {
1683 srna,
"ID Property",
"Property that stores arbitrary, user defined properties");
1739 "rna_IDPArray_begin",
1740 "rna_iterator_array_next",
1741 "rna_iterator_array_end",
1742 "rna_iterator_array_get",
1743 "rna_IDPArray_length",
1774 srna,
"rna_PropertyGroup_register",
"rna_PropertyGroup_unregister",
nullptr);
1787 "Unique name used in the code and scripting, can be re-defined in "
1788 "Python sub-classes if needed");
1806 parm =
RNA_def_pointer(func,
"material",
"Material",
"",
"Material to add");
1814 parm =
RNA_def_pointer(func,
"material",
"Material",
"",
"Material to remove");
1837 "True if this preview image has been modified by py script, "
1838 "and is no more auto-generated by Blender");
1841 srna,
"image_size", 2,
nullptr, 0, 0,
"Image Size",
"Width and height in pixels", 0, 0);
1844 prop,
"rna_ImagePreview_image_size_get",
"rna_ImagePreview_image_size_set",
nullptr);
1852 prop,
"rna_ImagePreview_image_pixels_get",
"rna_ImagePreview_image_pixels_set",
nullptr);
1858 prop,
"Float Image Pixels",
"Image pixels components, as floats (RGBA concatenated values)");
1861 "rna_ImagePreview_image_pixels_float_get",
1862 "rna_ImagePreview_image_pixels_float_set",
1870 "True if this preview icon has been modified by py script, "
1871 "and is no more auto-generated by Blender");
1874 srna,
"icon_size", 2,
nullptr, 0, 0,
"Icon Size",
"Width and height in pixels", 0, 0);
1877 prop,
"rna_ImagePreview_icon_size_get",
"rna_ImagePreview_icon_size_set",
nullptr);
1885 prop,
"rna_ImagePreview_icon_pixels_get",
"rna_ImagePreview_icon_pixels_set",
nullptr);
1891 prop,
"Float Icon Pixels",
"Icon pixels components, as floats (RGBA concatenated values)");
1894 "rna_ImagePreview_icon_pixels_float_get",
1895 "rna_ImagePreview_icon_pixels_float_set",
1904 "Unique integer identifying this preview as an icon (zero means invalid)",
1924 "For templates, prevents the user from removing predefined operation (NOT USED)"},
1929 "Prevents the user from modifying that override operation (NOT USED)"},
1931 "IDPOINTER_MATCH_REFERENCE",
1934 "The ID pointer overridden by this operation is expected to match the reference hierarchy"},
1936 "IDPOINTER_ITEM_USE_ID",
1938 "ID Item Use ID Pointer",
1939 "RNA collections of IDs only, the reference to the item also uses the ID pointer itself, "
1940 "not only its name"},
1941 {0,
nullptr, 0,
nullptr,
nullptr},
1944 srna =
RNA_def_struct(brna,
"IDOverrideLibraryPropertyOperation",
nullptr);
1946 "ID Library Override Property Operation",
1947 "Description of an override operation over an overridden property");
1954 "What override operation is performed");
1958 srna,
"flag", override_library_property_flag_items, 0,
"Flags",
"Status flags");
1962 "subitem_reference_name",
1965 "Subitem Reference Name",
1966 "Used to handle changes into collection");
1969 "rna_ID_override_library_property_operation_refname_get",
1970 "rna_ID_override_library_property_operation_refname_length",
1974 "subitem_local_name",
1977 "Subitem Local Name",
1978 "Used to handle changes into collection");
1981 "rna_ID_override_library_property_operation_locname_get",
1982 "rna_ID_override_library_property_operation_locname_length",
1986 "subitem_reference_id",
1988 "Subitem Reference ID",
1989 "Collection of IDs only, used to disambiguate between potential IDs with "
1990 "same name from different libraries");
1997 "Collection of IDs only, used to disambiguate between potential IDs with "
1998 "same name from different libraries");
2002 "subitem_reference_index",
2006 "Subitem Reference Index",
2007 "Used to handle changes into collection",
2013 "subitem_local_index",
2017 "Subitem Local Index",
2018 "Used to handle changes into collection",
2028 "UI label to display in dedicated view of the Outliner, in place of the "
2029 "actual UI widget to edit the value");
2032 "rna_ID_override_library_property_operation_label_get",
2033 "rna_ID_override_library_property_operation_label_length",
2041 "UI tooltip to display in dedicated view of the Outliner, when the label "
2042 "itself cannot provide all required information");
2045 "rna_ID_override_library_property_operation_tooltip_get",
2046 "rna_ID_override_library_property_operation_tooltip_length",
2057 srna =
RNA_def_struct(brna,
"IDOverrideLibraryPropertyOperations",
nullptr);
2062 func =
RNA_def_function(srna,
"add",
"rna_ID_override_library_property_operations_add");
2070 "What override operation is performed");
2076 "Use ID Pointer Subitem",
2077 "Whether the found or created liboverride operation should use ID pointers or not");
2079 "subitem_reference_name",
2082 "Subitem Reference Name",
2083 "Used to handle insertions or ID replacements into collection");
2085 "subitem_local_name",
2088 "Subitem Local Name",
2089 "Used to handle insertions or ID replacements into collection");
2091 "subitem_reference_id",
2093 "Subitem Reference ID",
2094 "Used to handle ID replacements into collection");
2099 "Used to handle ID replacements into collection");
2101 "subitem_reference_index",
2105 "Subitem Reference Index",
2106 "Used to handle insertions or ID replacements into collection",
2110 "subitem_local_index",
2114 "Subitem Local Index",
2115 "Used to handle insertions or ID replacements into collection",
2120 "IDOverrideLibraryPropertyOperation",
2122 "Created operation");
2126 func =
RNA_def_function(srna,
"remove",
"rna_ID_override_library_property_operations_remove");
2131 "IDOverrideLibraryPropertyOperation",
2133 "Override operation to be deleted");
2142 srna =
RNA_def_struct(brna,
"IDOverrideLibraryProperty",
nullptr);
2144 srna,
"ID Library Override Property",
"Description of an overridden property");
2153 "RNA path leading to that property, from owning ID");
2158 "IDOverrideLibraryPropertyOperation",
2160 "List of overriding operations for a property");
2174 srna =
RNA_def_struct(brna,
"IDOverrideLibraryProperties",
nullptr);
2179 func =
RNA_def_function(srna,
"add",
"rna_ID_override_library_properties_add");
2181 func,
"Add a property to the override library when it doesn't exist yet");
2185 "IDOverrideLibraryProperty",
2187 "Newly created override property or existing one");
2191 func,
"rna_path",
nullptr, 256,
"RNA Path",
"RNA-Path of the property to add");
2194 func =
RNA_def_function(srna,
"remove",
"rna_ID_override_library_properties_remove");
2199 "IDOverrideLibraryProperty",
2201 "Override property to be deleted");
2214 srna,
"ID Library Override",
"Struct gathering all data needed by overridden linked IDs");
2217 srna,
"reference",
"ID",
"Reference ID",
"Linked ID used as reference by this override");
2224 "Hierarchy Root ID",
2225 "Library override ID used as root of the override hierarchy this ID is a member of");
2231 "Whether this library override is defined as part of a library "
2232 "hierarchy, or as a single, isolated and autonomous override");
2238 "is_system_override",
2240 "Is System Override",
2241 "Whether this library override exists only for the override hierarchy, "
2242 "or if it is actually editable by the user");
2249 "IDOverrideLibraryProperty",
2251 "List of overridden properties");
2256 func =
RNA_def_function(srna,
"operations_update",
"rna_ID_override_library_operations_update");
2259 "Update the library override operations based on the "
2260 "differences between this override ID and its reference");
2264 "Reset this override to match again its linked reference ID");
2271 "Also reset all the dependencies of this override to match their reference linked IDs");
2273 "set_system_override",
2276 "Reset all user-editable overrides as (non-editable) system overrides");
2278 func =
RNA_def_function(srna,
"destroy",
"rna_ID_override_library_destroy");
2280 func,
"Delete this override ID and remap its usages to its linked reference ID instead");
2286 "Also delete all the dependencies of this override and remap their usages to "
2287 "their reference linked IDs");
2291 func,
"Resync the data-block and its sub-hierarchy, or the whole hierarchy if requested");
2294 func,
"success",
false,
"Success",
"Whether the resync process was successful or not");
2301 "The scene to operate in (for contextual things like keeping active object active, ensuring "
2302 "all overridden objects remain instantiated, etc.)");
2308 "The view layer to operate in (same usage as the ``scene`` data, in case "
2309 "it is not provided the scene's collection will be used instead)");
2315 "Collection where to store objects that are instantiated in any other collection anymore "
2316 "(garbage collection, will be created if needed and none is provided)");
2318 "do_hierarchy_enforce",
2321 "Enforce restoring the dependency hierarchy between data-blocks to match the "
2322 "one from the reference linked hierarchy (WARNING: if some ID pointers have "
2323 "been purposely overridden, these will be reset to their default value)");
2326 "do_whole_hierarchy",
2329 "Resync the whole hierarchy this data-block belongs to, not only its own sub-hierarchy");
2344 {0,
nullptr, 0,
nullptr,
nullptr},
2352 "Never rename an existing ID whose name would conflict, the currently renamed ID will get "
2353 "a numeric suffix appended to its new name"},
2358 "Always rename an existing ID whose name would conflict, ensuring that the currently "
2359 "renamed ID will get requested name"},
2363 "Rename If Same Root",
2364 "Only rename an existing ID whose name would conflict if its name root (everything besides "
2365 "the numerical suffix) is the same as the existing name of the currently renamed ID"},
2366 {0,
nullptr, 0,
nullptr,
nullptr},
2374 "The ID was not renamed, e.g. because it is already named as requested"},
2376 "UNCHANGED_COLLISION",
2378 "Unchanged Due to Collision",
2379 "The ID was not renamed, because requested name would have collided with another existing "
2380 "ID's name, and the automatically adjusted name was the same as the current ID's name"},
2382 "RENAMED_NO_COLLISION",
2384 "Renamed Without Collision",
2385 "The ID was renamed as requested, without creating any name collision"},
2387 "RENAMED_COLLISION_ADJUSTED",
2389 "Renamed With Collision",
2390 "The ID was renamed with adjustment of the requested name, to avoid a name collision"},
2392 "RENAMED_COLLISION_FORCED",
2394 "Renamed Enforced With Collision",
2395 "The ID was renamed as requested, also renaming another ID to avoid a name collision"},
2396 {0,
nullptr, 0,
nullptr,
nullptr},
2403 "Base type for data-blocks, defining a unique name, linking from other libraries "
2404 "and garbage collection");
2412 prop,
"Name",
"Unique data-block ID name (within a same type and library)");
2422 prop,
"Full Name",
"Unique data-block ID name, including library one if any");
2439 "A session-wide unique identifier for the data block that remains the "
2440 "same across renames and internal reallocations, unchanged when reloading the file");
2447 "Linked Packed Deep Hash",
2448 "Hash representing a unique version of a packed linked data and all of its dependencies");
2457 "Whether this ID is runtime-only, evaluated data-block, or actual data from .blend file");
2466 "Actual data-block from .blend file (Main database) that generated that evaluated one");
2488 "Indicates whether an extra user is set or not (mainly for internal/debug usages)");
2497 "This data-block is not an independent one, but is actually a sub-data of another ID "
2498 "(typical example: root node trees or master collections)");
2504 prop,
"Linked Packed",
"This data-block is linked and packed into the .blend file");
2511 "This data-block is a place-holder for missing linked data (i.e. it is "
2512 "[an override of] a linked data that could not be found anymore)");
2521 "This data-block is runtime data, i.e. it won't be saved in .blend "
2522 "file. Note that e.g. evaluated IDs are always runtime, so this value "
2523 "is only editable for data-blocks in Main data-base.");
2530 "This data-block is editable in the user interface. Linked data-blocks "
2531 "are not editable, except if they were loaded as editable assets.");
2538 "Tools can use this to tag data for their own purposes "
2539 "(initial state is undefined)");
2554 "library_weak_reference",
2555 "LibraryWeakReference",
2556 "Library Weak Reference",
2557 "Weak reference to the data-block in a library .blend file this "
2558 "originated from. For re-use of already appended data and linked editable assets");
2569 srna,
"override_library",
"IDOverrideLibrary",
"Library Override",
"Library override data");
2578 "Preview image and icon of this data-block (always None if not supported "
2579 "for this type of data)");
2587 func,
"More refined handling in case the new name collides with another ID's name");
2594 "New name to rename the ID to, if empty will re-use the current ID name");
2601 "How to handle name collision, in case the requested new name is already "
2602 "used by another ID of the same type");
2605 rename_result_items,
2608 "How did the renaming of the data-block went on");
2614 "Get corresponding evaluated ID from the given dependency graph. Note that this does not "
2615 "ensure the dependency graph is fully evaluated, it just returns the result of the last "
2618 func,
"depsgraph",
"Depsgraph",
"",
"Dependency graph to perform lookup in");
2627 "Create a copy of this data-block (not supported for all data-blocks). "
2628 "The result is added to the Blend-File Data (Main database), with all references to other "
2629 "data-blocks ensured to be from within the same Blend-File Data.");
2637 "Enable easier reuse of the data-block through the Asset Browser, with the help of "
2638 "customizable metadata (like previews, descriptions and tags)");
2643 "Delete all asset metadata and turn the asset data-block back into a normal data-block");
2645 func =
RNA_def_function(srna,
"asset_generate_preview",
"rna_ID_asset_generate_preview");
2647 func,
"Generate preview image (might be scheduled in a background thread)");
2650 func =
RNA_def_function(srna,
"override_create",
"rna_ID_override_create");
2652 "Create an overridden local copy of this linked data-block (not "
2653 "supported for all data-blocks)");
2655 parm =
RNA_def_pointer(func,
"id",
"ID",
"",
"New overridden local copy of the ID");
2658 "remap_local_usages",
2661 "Whether local usages of the linked ID should be remapped to the new "
2662 "library override of it");
2664 func =
RNA_def_function(srna,
"override_hierarchy_create",
"rna_ID_override_hierarchy_create");
2667 "Create an overridden local copy of this linked data-block, and most of its dependencies "
2668 "when it is a Collection or and Object");
2670 parm =
RNA_def_pointer(func,
"id",
"ID",
"",
"New overridden local copy of the root ID");
2673 func,
"scene",
"Scene",
"",
"In which scene the new overrides should be instantiated");
2679 "In which view layer the new overrides should be instantiated");
2685 "Another ID (usually an Object or Collection) used as a hint to decide where to "
2686 "instantiate the new overrides");
2688 "do_fully_editable",
2691 "Make all library overrides generated by this call fully editable by the user "
2692 "(none will be 'system overrides')");
2696 "Clear the user count of a data-block so its not saved, "
2697 "on reload the data will be removed");
2701 func,
"Replace all usage in the .blend file of this ID by new given one");
2709 "Make this data-block local, return local one "
2710 "(may be a copy of the original, in case it is also indirectly used)");
2712 parm =
RNA_def_boolean(func,
"clear_proxy",
true,
"",
"Deprecated, has no effect");
2714 "clear_liboverride",
2717 "Remove potential library override data from the newly made local data");
2723 "Remove potential asset metadata so the newly local data-block is not treated as asset "
2724 "data-block and won't show up in asset libraries");
2725 parm =
RNA_def_pointer(func,
"id",
"ID",
"",
"This ID, or the new ID if it was copied");
2731 "Count the number of times that ID uses/references given one");
2740 "Number of usages/references of given id by current data-block",
2745 func =
RNA_def_function(srna,
"animation_data_create",
"rna_ID_animation_data_create");
2748 func,
"Create animation data to this ID, note that not all ID types support this");
2749 parm =
RNA_def_pointer(func,
"anim_data",
"AnimData",
"",
"New animation data or None");
2752 func =
RNA_def_function(srna,
"animation_data_clear",
"rna_ID_animation_data_free");
2759 "Tag the ID to update its display data, "
2760 "e.g. when calling :class:`bpy.types.ViewLayer.update`");
2761 RNA_def_enum_flag(func,
"refresh", update_flag_items, 0,
"",
"Type of updates to perform");
2763 func =
RNA_def_function(srna,
"preview_ensure",
"BKE_previewimg_id_ensure");
2765 "Ensure that this ID has preview data (if ID type supports it)");
2767 func,
"preview_image",
"ImagePreview",
"",
"The existing or created preview");
2790 "Path to the library .blend file. WARNING: Typically, this value "
2791 "should be considered read-only, changing this path without proper "
2792 "processing afterwards can leave Blender data in an invalid state");
2812 "Version of Blender the library .blend was saved with",
2822 "Library Overrides Need resync",
2823 "True if this library contains library overrides that are linked in "
2824 "current blend-file, and that had to be recursively resynced on load "
2825 "(it is recommended to open and re-save that library blend-file then)");
2832 "Data-blocks in this library are editable despite being linked. "
2833 "Used by brush assets and their dependencies.");
2840 "This library is an 'archive' storage for packed linked IDs "
2841 "originally linked from its 'archive parent' library.");
2848 "Parent Archive Library",
2849 "Source library from which this archive of packed IDs was generated");
2854 "rna_Library_archive_libraries_begin",
2855 "rna_Library_archive_libraries_next",
2857 "rna_Library_archive_libraries_get",
2858 "rna_Library_archive_libraries_length",
2859 "rna_Library_archive_libraries_lookupint",
2865 "Archive Libraries",
2866 "Archive libraries of packed IDs, generated (and owned) by this source library");
2881 "LibraryWeakReference",
2882 "Read-only external reference to a linked data-block and its library file");
2894 "Full ID name in the library .blend file (including the two leading 'id type' chars)");
2920 srna,
"Unknown Type",
"Stub RNA type used for pointers to unknown or internal data");
#define IDP_property_array_get(prop)
General operations, lookup, etc. for materials.
external readfile function prototypes.
#define BLT_I18NCONTEXT_ID_ID
#define BPy_BEGIN_ALLOW_THREADS
#define BPy_END_ALLOW_THREADS
ID and Library types, which are fundamental for SDNA.
#define FILTER_ID_GD_LEGACY
#define ID_IS_PACKED(_id)
#define ID_IS_OVERRIDE_LIBRARY_REAL(_id)
#define ID_IS_OVERRIDABLE_LIBRARY(_id)
#define FILTER_ID_CU_LEGACY
#define ID_IS_LINKED(_id)
#define ID_IS_EDITABLE(_id)
#define RNA_MAX_ARRAY_DIMENSION
#define ND_LIB_OVERRIDE_CHANGED
SIMD_FORCE_INLINE btScalar length() const
Return the length of the vector.
ccl_device_inline dual1 len(const ccl_private dual< T > &a)
int size(const AssetLibraryReference *library_reference)
bool copy_to_id(const AssetMetaData *asset_data, ID *destination)
void generate_preview(const bContext *C, ID *id)
void refresh_for_srna_unregister(Main *bmain, StructRNA *srna_to_unreg)
void WM_main_add_notifier(uint type, void *reference)
static void rna_def_ID(BlenderRNA *brna)
void RNA_def_property_srna(PropertyRNA *prop, const char *type)
BLI_assert(slot->slot_subtype.map==BMO_OP_SLOT_SUBTYPE_MAP_FLT)
void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description)
void rna_ID_name_set(PointerRNA *ptr, const char *value)
void RNA_def_property_editable_func(PropertyRNA *prop, const char *editable)
void rna_ID_name_get(PointerRNA *ptr, char *value)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
void RNA_def_property_dynamic_array_funcs(PropertyRNA *prop, const char *getlength)
void RNA_def_struct_ui_icon(StructRNA *srna, int icon)
void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname)
int(*)(PointerRNA *ptr, void *data, bool *have_function) StructValidateFunc
@ LIBRARY_TAG_RESYNC_REQUIRED
MINLINE unsigned char unit_float_to_uchar_clamp(float val)
const EnumPropertyItem rna_enum_id_type_items[]
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void BKE_previewimg_clear(PreviewImage *prv)
@ RPT_ERROR_INVALID_INPUT
void RNA_def_property_boolean_negative_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void BKE_id_delete(Main *bmain, void *idv, const BKEIDDeleteOptions &options={}) ATTR_NONNULL()
@ STRUCT_NO_DATABLOCK_IDPROPERTIES
bool BKE_lib_override_library_create(Main *bmain, Scene *scene, ViewLayer *view_layer, Library *owner_library, ID *id_root_reference, ID *id_hierarchy_root_reference, ID *id_instance_hint, ID **r_id_root_override, const bool do_fully_editable)
void BKE_previewimg_clear_single(PreviewImage *prv, enum eIconSizes size)
bool BKE_vfont_is_builtin(const VFont *vfont)
void RNA_def_property_float_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void RNA_def_property_pointer_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_pointer_funcs(PropertyRNA *prop, const char *get, const char *set, const char *type_fn, const char *poll)
PointerRNA RNA_id_pointer_create(ID *id)
static void rna_def_ID_override_library_property_operations(BlenderRNA *brna, PropertyRNA *cprop)
void RNA_def_struct_refine_func(StructRNA *srna, const char *refine)
void RNA_def_property_boolean_funcs(PropertyRNA *prop, const char *get, const char *set)
StructRNA * ID_code_to_RNA_type(short idcode)
void RNA_def_property_multi_array(PropertyRNA *prop, int dimension, const int length[])
void RNA_def_struct_system_idprops_func(StructRNA *srna, const char *system_idproperties)
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
void void BKE_libblock_remap(Main *bmain, void *old_idv, void *new_idv, int remap_flags) ATTR_NONNULL(1
short * BKE_id_material_len_p(ID *id)
ID * BKE_id_copy_for_use_in_bmain(Main *bmain, const ID *id)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_int_vector(StructOrFunctionRNA *cont_, const char *identifier, const int len, const int *default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
static void rna_def_ID_materials(BlenderRNA *brna)
short RNA_type_to_ID_code(const StructRNA *type)
PropertyRNA * RNA_def_pointer(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void rna_pointer_create_with_ancestors(const PointerRNA &parent, StructRNA *type, void *data, PointerRNA &r_ptr)
const IDFilterEnumPropertyItem rna_enum_id_type_filter_items[]
ID * BKE_lib_override_library_create_from_id(Main *bmain, ID *reference_id, bool do_tagged_remap)
void RNA_def_property_struct_type(PropertyRNA *prop, const char *type)
@ ID_REMAP_SKIP_NEVER_NULL_USAGE
@ ID_REMAP_SKIP_INDIRECT_USAGE
bool BKE_lib_override_library_resync(Main *bmain, Scene *scene, ViewLayer *view_layer, ID *id_root, Collection *override_resync_residual_storage, bool do_hierarchy_enforce, BlendFileReadReport *reports)
static const EnumPropertyItem rna_enum_override_library_property_operation_items[]
static void rna_def_ID_override_library_properties(BlenderRNA *brna, PropertyRNA *cprop)
bool id_can_have_animdata(const ID *id)
void id_fake_user_set(ID *id)
@ LIBOVERRIDE_OP_INSERT_AFTER
@ LIBOVERRIDE_OP_SUBTRACT
@ LIBOVERRIDE_OP_MULTIPLY
@ LIBOVERRIDE_OP_INSERT_BEFORE
void id_us_clear_real(ID *id)
void RNA_def_property_string_maxlength(PropertyRNA *prop, int maxlength)
@ LIBOVERRIDE_FLAG_NO_HIERARCHY
@ LIBOVERRIDE_FLAG_SYSTEM_DEFINED
StructRNA RNA_PropertyGroup
AnimData * BKE_animdata_ensure_id(ID *id)
@ PROPOVERRIDE_OVERRIDABLE_LIBRARY
@ PROPOVERRIDE_NO_COMPARISON
void rna_ID_fake_user_set(PointerRNA *ptr, bool value)
IDProperty ** rna_PropertyGroup_idprops(PointerRNA *ptr)
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier_c_str, int type, int subtype)
int BLI_findindex(const ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
static void rna_def_image_preview(BlenderRNA *brna)
void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
static void rna_def_library(BlenderRNA *brna)
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
void DEG_id_tag_update_ex(Main *bmain, ID *id, unsigned int flags)
StructRNA * rna_ID_refine(PointerRNA *ptr)
void RNA_struct_free(BlenderRNA *brna, StructRNA *srna)
void BKE_id_material_assign(Main *bmain, ID *id, Material *ma, short act)
void BKE_lib_override_library_delete(Main *bmain, ID *id_root)
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_def_property_collection_funcs(PropertyRNA *prop, const char *begin, const char *next, const char *end, const char *get, const char *length, const char *lookupint, const char *lookupstring, const char *assignint)
void RNA_def_property_int_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void DEG_id_tag_update(ID *id, unsigned int flags)
bool rna_PropertyGroup_unregister(Main *bmain, StructRNA *type)
void BKE_report(ReportList *reports, eReportType type, const char *message)
BMesh const char void * data
void RNA_def_property_override_flag(PropertyRNA *prop, PropertyOverrideFlag flag)
T * DEG_get_evaluated(const Depsgraph *depsgraph, T *id)
void BKE_animdata_free(ID *id, bool do_id_user)
void RNA_def_property_boolean_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void BKE_id_material_append(Main *bmain, ID *id, Material *ma)
void BKE_main_ensure_invariants(Main &bmain, std::optional< Span< ID * > > modified_ids=std::nullopt)
bool BKE_vfont_to_curve(Object *ob, eEditFontMode mode)
StructRNA * rna_PropertyGroup_refine(PointerRNA *ptr)
PreviewImage * BKE_previewimg_id_ensure(ID *id)
void BKE_lib_override_library_make_local(Main *bmain, ID *id)
void RNA_def_property_subtype(PropertyRNA *prop, PropertySubType subtype)
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
Material * BKE_id_material_pop(Main *bmain, ID *id, int index)
void BKE_id_newptr_and_tag_clear(ID *id)
int char char int int int int size_t BLI_strnlen(const char *str, size_t maxlen) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
int BKE_icon_preview_ensure(ID *id, PreviewImage *preview)
PointerRNA RNA_pointer_create_discrete(ID *id, StructRNA *type, void *data)
void BKE_lib_override_library_property_operation_delete(IDOverrideLibraryProperty *liboverride_property, IDOverrideLibraryPropertyOperation *liboverride_property_operation)
static void rna_def_library_weak_reference(BlenderRNA *brna)
void BKE_lib_override_library_id_reset(Main *bmain, ID *id_root, bool do_reset_system_override)
const EnumPropertyItem rna_enum_dummy_DEFAULT_items[]
void RNA_def_property_enum_funcs(PropertyRNA *prop, const char *get, const char *set, const char *item)
@ LIBRARY_FLAG_IS_ARCHIVE
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier_c_str, const char *call)
void WM_lib_reload(Library *lib, bContext *C, ReportList *reports)
void(*)(void *data) StructFreeFunc
void RNA_def_struct_register_funcs(StructRNA *srna, const char *reg, const char *unreg, const char *instance)
void BKE_main_id_tag_all(Main *mainvar, int tag, bool value)
static void rna_def_ID_override_library(BlenderRNA *brna)
void BKE_id_material_clear(Main *bmain, ID *id)
StructRNA * rna_PropertyGroup_register(Main *bmain, ReportList *reports, void *data, const char *identifier, StructValidateFunc validate, StructCallbackFunc call, StructFreeFunc free)
PreviewImage * BKE_previewimg_id_get(const ID *id)
PropertyRNA * RNA_def_collection(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
void RNA_def_property_clear_flag(PropertyRNA *prop, PropertyFlag flag)
const char * RNA_struct_identifier(const StructRNA *type)
void RNA_def_struct_idprops_func(StructRNA *srna, const char *idproperties)
void BKE_library_filepath_set(Main *bmain, Library *lib, const char *filepath)
void id_us_ensure_real(ID *id)
void RNA_def_function_flag(FunctionRNA *func, FunctionFlag flag)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, const int default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
const StructRNA * RNA_struct_base_child_of(const StructRNA *type, const StructRNA *parent_type)
void RNA_def_struct_flag(StructRNA *srna, StructFlag flag)
void BKE_reportf(ReportList *reports, eReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
T * DEG_get_original(T *id)
void ** rna_ID_instance(PointerRNA *ptr)
static void rna_def_ID_override_library_property(BlenderRNA *brna)
IDOverrideLibraryProperty * BKE_lib_override_library_property_get(IDOverrideLibrary *liboverride, const char *rna_path, bool *r_created)
StructRNA * RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from)
ID_Type GS(const char *name)
@ PROP_PATH_SUPPORTS_BLEND_RELATIVE
void RNA_def_property_int_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void BPY_free_srna_pytype(StructRNA *srna)
int rna_ID_name_length(PointerRNA *ptr)
void RNA_def_ID(BlenderRNA *brna)
IDProperty ** rna_ID_idprops(PointerRNA *ptr)
PropertyRNA * RNA_def_enum_flag(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *func)
void BKE_id_full_name_get(char name[MAX_ID_FULL_NAME], const ID *id, char separator_char)
PointerRNA RNA_pointer_create_with_parent(const PointerRNA &parent, StructRNA *type, void *data)
void BKE_previewimg_ensure(PreviewImage *prv, int size)
void DEG_relations_tag_update(Main *bmain)
IDNewNameResult BKE_id_rename(Main &bmain, ID &id, StringRefNull name, const IDNewNameMode mode=IDNewNameMode::RenameExistingNever)
@ ID_FLAG_LINKED_AND_PACKED
void RNA_def_property_string_funcs(PropertyRNA *prop, const char *get, const char *length, const char *set)
@ LIB_ID_MAKELOCAL_ASSET_DATA_CLEAR
static void rna_def_ID_override_library_property_operation(BlenderRNA *brna)
static void rna_def_ID_properties(BlenderRNA *brna)
void BKE_lib_override_library_operations_create(Main *bmain, ID *local, int *r_report_flags)
bool BKE_lib_id_make_local(Main *bmain, ID *id, int flags)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
void BKE_lib_override_library_property_delete(IDOverrideLibrary *liboverride, IDOverrideLibraryProperty *liboverride_property)
static void rna_def_idproperty_wrap_ptr(BlenderRNA *brna)
void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop, const bool allow_replace)
bool BKE_id_is_in_global_main(ID *id)
void BKE_lib_override_library_id_hierarchy_reset(Main *bmain, ID *id_root, bool do_reset_system_override)
void id_fake_user_clear(ID *id)
void RNA_def_property_array(PropertyRNA *prop, int length)
IDOverrideLibraryPropertyOperation * BKE_lib_override_library_property_operation_get(IDOverrideLibraryProperty *liboverride_property, eID_OverrideLib_Op operation, const char *subitem_refname, const char *subitem_locname, const std::optional< ID * > &subitem_refid, const std::optional< ID * > &subitem_locid, int subitem_refindex, int subitem_locindex, bool strict, bool *r_strict, bool *r_created)
@ LIBOVERRIDE_OP_FLAG_IDPOINTER_ITEM_USE_ID
@ LIBOVERRIDE_OP_FLAG_MANDATORY
@ LIBOVERRIDE_OP_FLAG_LOCKED
@ LIBOVERRIDE_OP_FLAG_IDPOINTER_MATCH_REFERENCE
void RNA_def_property_ui_icon(PropertyRNA *prop, int icon, int consecutive)
void rna_iterator_array_begin(CollectionPropertyIterator *iter, PointerRNA *ptr, void *data, size_t itemsize, int64_t length, bool free_ptr, IteratorSkipFunc skip)
int(*)(bContext *C, PointerRNA *ptr, FunctionRNA *func, ParameterList *list) StructCallbackFunc
IDProperty ** rna_ID_system_idprops(PointerRNA *ptr)
void * MEM_new_array_zeroed(size_t len, size_t size, const char *str) ATTR_WARN_UNUSED_RESULT ATTR_ALLOC_SIZE(1
BlenderRNA RNA_blender_rna_get()
bool rna_IDMaterials_assign_int(PointerRNA *ptr, int key, const PointerRNA *assign_ptr)
StructRNA * RNA_def_struct_ptr(BlenderRNA *brna, const char *identifier, StructRNA *srnafrom)
@ RENAMED_COLLISION_FORCED
@ RENAMED_COLLISION_ADJUSTED
IDProperty * system_properties
bke::library::LibraryRuntime * runtime
Vector< Library * > archived_libraries