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/blenloader/intern')
-rw-r--r--source/blender/blenloader/intern/readblenentry.c5
-rw-r--r--source/blender/blenloader/intern/readfile.c22
-rw-r--r--source/blender/blenloader/intern/readfile.h10
-rw-r--r--source/blender/blenloader/intern/undofile.c1
-rw-r--r--source/blender/blenloader/intern/versioning_290.c12
-rw-r--r--source/blender/blenloader/intern/versioning_300.c17
-rw-r--r--source/blender/blenloader/intern/writefile.c2
7 files changed, 25 insertions, 44 deletions
diff --git a/source/blender/blenloader/intern/readblenentry.c b/source/blender/blenloader/intern/readblenentry.c
index f3c92aec338..f01d6afb22d 100644
--- a/source/blender/blenloader/intern/readblenentry.c
+++ b/source/blender/blenloader/intern/readblenentry.c
@@ -15,11 +15,11 @@
*
* The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
* All rights reserved.
- * .blend file reading entry point
*/
/** \file
* \ingroup blenloader
+ * `.blend` file reading entry point.
*/
#include <stddef.h>
@@ -419,9 +419,6 @@ BlendFileData *BLO_read_from_memfile(Main *oldmain,
fd->skip_flags = params->skip_flags;
BLI_strncpy(fd->relabase, filename, sizeof(fd->relabase));
- /* clear ob->proxy_from pointers in old main */
- blo_clear_proxy_pointers_from_lib(oldmain);
-
/* separate libraries from old main */
blo_split_main(&old_mainlist, oldmain);
/* add the library pointers in oldmap lookup */
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 38f2d8bb22c..6757177a385 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -1580,15 +1580,6 @@ static void change_link_placeholder_to_real_ID_pointer(ListBase *mainlist,
}
}
-void blo_clear_proxy_pointers_from_lib(Main *oldmain)
-{
- LISTBASE_FOREACH (Object *, ob, &oldmain->objects) {
- if (ID_IS_LINKED(ob) && ob->proxy_from != NULL && !ID_IS_LINKED(ob->proxy_from)) {
- ob->proxy_from = NULL;
- }
- }
-}
-
/* XXX disabled this feature - packed files also belong in temp saves and quit.blend,
* to make restore work. */
@@ -2008,6 +1999,7 @@ static void lib_link_id(BlendLibReader *reader, ID *id)
if (id->override_library) {
BLO_read_id_address(reader, id->lib, &id->override_library->reference);
BLO_read_id_address(reader, id->lib, &id->override_library->storage);
+ BLO_read_id_address(reader, id->lib, &id->override_library->hierarchy_root);
}
lib_link_id_embedded_id(reader, id);
@@ -2997,7 +2989,7 @@ static const char *dataname(short id_code)
return "Data from CF";
case ID_WS:
return "Data from WS";
- case ID_HA:
+ case ID_CV:
return "Data from HA";
case ID_PT:
return "Data from PT";
@@ -3207,18 +3199,8 @@ static void read_libblock_undo_restore_identical(
id_old->recalc |= direct_link_id_restore_recalc_exceptions(id_old);
id_old->recalc_after_undo_push = 0;
- /* As usual, proxies require some special love...
- * In `blo_clear_proxy_pointers_from_lib()` we clear all `proxy_from` pointers to local IDs, for
- * undo. This is required since we do not re-read linked data in that case, so we also do not
- * re-'lib_link' their pointers.
- * Those `proxy_from` pointers are then re-defined properly when lib_linking the newly read local
- * object. However, in case of re-used data 'as-is', we never lib_link it again, so we have to
- * fix those backward pointers here. */
if (GS(id_old->name) == ID_OB) {
Object *ob = (Object *)id_old;
- if (ob->proxy != NULL) {
- ob->proxy->proxy_from = ob;
- }
/* For undo we stay in object mode during undo presses, so keep editmode disabled for re-used
* data-blocks too. */
ob->mode &= ~OB_MODE_EDIT;
diff --git a/source/blender/blenloader/intern/readfile.h b/source/blender/blenloader/intern/readfile.h
index 21b0354b097..d75aab9ba9c 100644
--- a/source/blender/blenloader/intern/readfile.h
+++ b/source/blender/blenloader/intern/readfile.h
@@ -15,11 +15,11 @@
*
* The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
* All rights reserved.
- * blenloader readfile private function prototypes
*/
/** \file
* \ingroup blenloader
+ * blenloader readfile private function prototypes.
*/
#pragma once
@@ -144,14 +144,6 @@ FileData *blo_filedata_from_memfile(struct MemFile *memfile,
const struct BlendFileReadParams *params,
struct BlendFileReadReport *reports);
-/**
- * Lib linked proxy objects point to our local data, we need
- * to clear that pointer before reading the undo memfile since
- * the object might be removed, it is set again in reading
- * if the local object still exists.
- * This is only valid for local proxy objects though, linked ones should not be affected here.
- */
-void blo_clear_proxy_pointers_from_lib(struct Main *oldmain);
void blo_make_packed_pointer_map(FileData *fd, struct Main *oldmain);
/**
* Set old main packed data to zero if it has been restored
diff --git a/source/blender/blenloader/intern/undofile.c b/source/blender/blenloader/intern/undofile.c
index dfa6135dac9..638e6a13b01 100644
--- a/source/blender/blenloader/intern/undofile.c
+++ b/source/blender/blenloader/intern/undofile.c
@@ -15,7 +15,6 @@
*
* The Original Code is Copyright (C) 2004 Blender Foundation
* All rights reserved.
- * .blend file reading entry point
*/
/** \file
diff --git a/source/blender/blenloader/intern/versioning_290.c b/source/blender/blenloader/intern/versioning_290.c
index 888bd244007..87b5da09a60 100644
--- a/source/blender/blenloader/intern/versioning_290.c
+++ b/source/blender/blenloader/intern/versioning_290.c
@@ -32,11 +32,11 @@
#include "DNA_cachefile_types.h"
#include "DNA_collection_types.h"
#include "DNA_constraint_types.h"
+#include "DNA_curves_types.h"
#include "DNA_fluid_types.h"
#include "DNA_genfile.h"
#include "DNA_gpencil_modifier_types.h"
#include "DNA_gpencil_types.h"
-#include "DNA_hair_types.h"
#include "DNA_light_types.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
@@ -1120,10 +1120,7 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
- /* Hair and PointCloud attributes. */
- for (Hair *hair = bmain->hairs.first; hair != NULL; hair = hair->id.next) {
- do_versions_point_attributes(&hair->pdata);
- }
+ /* PointCloud attributes. */
for (PointCloud *pointcloud = bmain->pointclouds.first; pointcloud != NULL;
pointcloud = pointcloud->id.next) {
do_versions_point_attributes(&pointcloud->pdata);
@@ -1422,10 +1419,7 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
- /* Hair and PointCloud attributes names. */
- LISTBASE_FOREACH (Hair *, hair, &bmain->hairs) {
- do_versions_point_attribute_names(&hair->pdata);
- }
+ /* PointCloud attributes names. */
LISTBASE_FOREACH (PointCloud *, pointcloud, &bmain->pointclouds) {
do_versions_point_attribute_names(&pointcloud->pdata);
}
diff --git a/source/blender/blenloader/intern/versioning_300.c b/source/blender/blenloader/intern/versioning_300.c
index 90730439c51..001dffdca10 100644
--- a/source/blender/blenloader/intern/versioning_300.c
+++ b/source/blender/blenloader/intern/versioning_300.c
@@ -1107,6 +1107,15 @@ static bool seq_transform_origin_set(Sequence *seq, void *UNUSED(user_data))
return true;
}
+static bool seq_transform_filter_set(Sequence *seq, void *UNUSED(user_data))
+{
+ StripTransform *transform = seq->strip->transform;
+ if (seq->strip->transform != NULL) {
+ transform->filter = SEQ_TRANSFORM_FILTER_BILINEAR;
+ }
+ return true;
+}
+
static void do_version_subsurface_methods(bNode *node)
{
if (node->type == SH_NODE_SUBSURFACE_SCATTERING) {
@@ -2549,6 +2558,14 @@ void blo_do_versions_300(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
+ if (!MAIN_VERSION_ATLEAST(bmain, 302, 2)) {
+ LISTBASE_FOREACH (Scene *, scene, &bmain->scenes) {
+ if (scene->ed != NULL) {
+ SEQ_for_each_callback(&scene->ed->seqbase, seq_transform_filter_set, NULL);
+ }
+ }
+ }
+
/**
* Versioning code until next subversion bump goes here.
*
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index aa3eef4b475..4eda63d0817 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -999,7 +999,7 @@ static void write_libraries(WriteData *wd, Main *main)
if (!BKE_idtype_idcode_is_linkable(GS(id->name))) {
printf(
"ERROR: write file: data-block '%s' from lib '%s' is not linkable "
- "but is flagged as directly linked",
+ "but is flagged as directly linked\n",
id->name,
main->curlib->filepath_abs);
BLI_assert(0);