1
1

Fix #106794: Changing active camera changes other viewport local cameras

f36543c5f5 took care of syncing multiple viewport`s cameras, but wasnt
fully meeting intentions [which was to only do this if both viewports
are locked to the scene camera].

Check was only done for the viewport this was executed in (if this was
locked to the scene camera, it would change all other viewports as
well), now also check if the target viewport prefers to use its own
local camera instead and skip it in that case.

Pull Request: blender/blender#106799

Pull Request: blender/blender#106858
This commit is contained in:
2023-04-12 10:10:12 +02:00
committed by Gitea
parent c2b517950a
commit 533e8ac3f3

View File

@@ -179,7 +179,8 @@ static void sync_viewport_camera_smoothview(bContext *C,
if (other_v3d->camera == ob) {
continue;
}
if (v3d->scenelock) {
/* Checking the other view is needed to prevent local cameras being modified. */
if (v3d->scenelock && other_v3d->scenelock) {
ListBase *lb = (space_link == area->spacedata.first) ? &area->regionbase :
&space_link->regionbase;
for (ARegion *other_region = lb->first; other_region != NULL;