diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2020-08-04 17:44:16 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2020-08-04 17:44:16 +0300 |
commit | 6197d4dafa8ee623f3779c883babb20a7555c992 (patch) | |
tree | 082750b7cb6f6c2612fa55597858f17310e83993 /source/blender/blenloader | |
parent | f0ed70eb12b81ed3fc97d7eeb88c2d7131aacb81 (diff) | |
parent | 21c31885eda9a2c041d975428cff0ec23faeffc6 (diff) |
Merge branch 'master' into greasepencil-edit-curve
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 4 | ||||
-rw-r--r-- | source/blender/blenloader/intern/versioning_280.c | 2 | ||||
-rw-r--r-- | source/blender/blenloader/intern/versioning_290.c | 11 |
3 files changed, 15 insertions, 2 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index e6d54550aa4..c24b4545e22 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -5145,6 +5145,9 @@ static void direct_link_pose(BlendDataReader *reader, bPose *pose) pose->chan_array = NULL; for (pchan = pose->chanbase.first; pchan; pchan = pchan->next) { + BKE_pose_channel_runtime_reset(&pchan->runtime); + BKE_pose_channel_session_uuid_generate(pchan); + pchan->bone = NULL; BLO_read_data_address(reader, &pchan->parent); BLO_read_data_address(reader, &pchan->child); @@ -5170,7 +5173,6 @@ static void direct_link_pose(BlendDataReader *reader, bPose *pose) CLAMP(pchan->rotmode, ROT_MODE_MIN, ROT_MODE_MAX); pchan->draw_data = NULL; - BKE_pose_channel_runtime_reset(&pchan->runtime); } pose->ikdata = NULL; if (pose->ikparam != NULL) { diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c index 74a07050d7d..4e3f701bacc 100644 --- a/source/blender/blenloader/intern/versioning_280.c +++ b/source/blender/blenloader/intern/versioning_280.c @@ -190,7 +190,7 @@ static void do_version_workspaces_create_from_screens(Main *bmain) static void do_version_area_change_space_to_space_action(ScrArea *area, const Scene *scene) { SpaceType *stype = BKE_spacetype_from_id(SPACE_ACTION); - SpaceAction *saction = (SpaceAction *)stype->new (area, scene); + SpaceAction *saction = (SpaceAction *)stype->create(area, scene); ARegion *region_channels; /* Properly free current regions */ diff --git a/source/blender/blenloader/intern/versioning_290.c b/source/blender/blenloader/intern/versioning_290.c index d2f45900325..94c9b125706 100644 --- a/source/blender/blenloader/intern/versioning_290.c +++ b/source/blender/blenloader/intern/versioning_290.c @@ -467,5 +467,16 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain) cache_file->velocity_unit = CACHEFILE_VELOCITY_UNIT_SECOND; } } + + if (!DNA_struct_elem_find(fd->filesdna, "OceanModifierData", "int", "viewport_resolution")) { + for (Object *object = bmain->objects.first; object != NULL; object = object->id.next) { + LISTBASE_FOREACH (ModifierData *, md, &object->modifiers) { + if (md->type == eModifierType_Ocean) { + OceanModifierData *omd = (OceanModifierData *)md; + omd->viewport_resolution = omd->resolution; + } + } + } + } } } |