'Lock Camera To View'... It was torture to find it!

I came from other software, and was very surprised by such a function in a blender as “Lock Camera To View”.
Because in other software, navigation in the “Camera View” was the same as navigation in the “3DViewport”, and if I need to block changing camera settings I’m just RMB on the Camera in the outliner and choose Lock/Unlock (lock icon appears near the camera icon in the outliner).

But I understand why Blender has this feature, it’s because no Undo/Redo for changes in the “Camera View”.
I can live with “Lock Camera To View”, but it definitely needs undo/redo feature.

4 Likes

no Undo/Redo for changes in the “Camera View”.

This missing undo/redo is some seriously annoying bulls***. God help you if you move the camera by accident.

2 Likes

I found this thread because of the title AND no undo/redo for accidental camera moves… I cannot believe this is true. I accidentally “spun” the mouse wheel and watched my perfectly placed camera fly around the center point of the viewport. I thought it had to be because I was an Uber-noob at Blender, though used C4D off and on for a couple decades. But, this is just app design 101…

Also, I cannot fathom how this thread has gone on so long without being noticed/implemented or significantly addressed. I feel fooled by the nice new 2.8+ UI icing, when what the Blender team needs is dedicated or volunteer UX designers (that have capacity to test with new users), or full fledged digital product designers.

1 Like

This has been on the developer’s radar but there have been some issues with the implementation. I guess a solution for this is still in the plans from 3.0 version.

https://developer.blender.org/D10835

https://developer.blender.org/D11195

2 Likes

We had the option, it was simple it was nice. A couple of Blender devs made Julian remove it cause they didn’t like the ascetics. It was suuuuuuuuuuper convenient to have right under the camera icon. The main problem is that we still don’t have something to replace it. Digging through the N panel is not a viable option. Raise your hand if you feel the camera is just as important to animate in a scene as any character on the screen.
I hope with the new animation push that Blender addresses this soon. Having to dig through the N panel is not cool.
I mean we had this already, and it had to be reverted!
https://archive.blender.org/developer/D10968

Just want to say that I can have up to 100 plus shots in a single scene each with their own camera. I like each shot to have its own separate camera for the different camera settings that are needed.
Opening N panel
Clicking on the View Tab
Finding “Lock Camera to View”
Clicking on “Lock camera to View”
Close N panel
Adjust camera
Rinse and repeat above just to untoggle the “Lock Camera to View”

Repeat for every camera.

One of my recommendations was for a long press on the camera Icon to trigger the lock; camera icon would then turn red. Long press again to untoggle the lock and camera icon returns to white.

6 Likes

Yeah, i second this, devs realy ought to bring it back, or anyone else for that matter, someone bug a dev about this directly or make someone do a commit to revert it back.

There realy is no place in blender to remove a Very useful Feature without offering a better alternative, otherwise its just a crime to remove it.

1 Like

I’m all for it. I understand the “it’s not the blender way” argument - but it was an improvement. And shooting something down without offering a better solution often just stalls progress. :face_with_diagonal_mouth:
In some parts Blender has a very convoluted way of doing things. Yes - consistency is king but maybe even a king could die in in a dead end, some time. :sweat_smile:

2 Likes

I’ve read the D10968 Revision, and I do not understand at all.

“One reason to revert it is simply the process: We should aim for the highest possible standards.”

The Lock Camera function is practically buried in the program - far from any possible high standard.

What is the reason for the change? Discoverability? Convenience? Is it more of an indicator? It still seems uncertain.

The new user is present with a camera, and the moment they hit F12 they wonder why they don’t see a rendered image of their viewport. They click the round Camera icon, which shows them the render area, drag their mouse to reposition, and immediately the Camera jumps - “No, sorry… let’s go back to non-camera view.” Then they spend quite a lot of time on the internet trying to understand this strange behavior.

Combine this with “orbit around selection” being Unchecked by default in the preferences, and it is a terrible new-user experience. Whether re-introduced as a round button, or a square toggle next to the shader-mode buttons in the header, the camera lock feature needs much higher visibility/access in the program.

It is also not merely a matter for new users; I toggle this option on a regular basis to check changes in the scene against the final render, and having to visit the sidebar closet, change the tab I’m actually using, click a checkbox, go back to the tab I was using - yes, that’s a high matter of convenience.

8 Likes

Aiming for the highest of standards, a bed of Procrustes! :yum:

The diff has 31 positive tokens. It is rare that any diff got anything near that amount of response.

It is all three. It seems that the uncertainty is due to not having only one reason?

3 Likes

Quick fix for you:
open space_view3d.py
throw this wherever you want it in the viewport header

row = layout.row(align=True)
row.prop(view, "lock_camera", text="", icon='CAMERA_DATA')

if you are putting this somewhere that doesn’t already have a reference for ‘view’ you’ll need to add this

view = context.space_data

Change the icon and/or text to whatever you want. Turn on the icon viewer addon to see them inside of the scripting tab, searchable. If you are doing this a lot, just add it to a shortcut. Can still use the header icon as a reference to it being on or not

Some camera icons:
These appear to be identical, a line drawing of a camera, no idea why this is necessary, maybe they were different at some point?
OUTLINER_DATA_CAMERA
CAMERA_DATA

These are a white filled in version of the same, they have the subtlest of difference between them, you wouldn’t know without flipping back and forth in the icon viewer
VIEW_CAMERA
OUTLINER_OB_CAMERA

If you want something that looks like a camera, but a little different
CON_CAMERASOLVER

5 Likes

IIRC Pablo mentioned in the stream that it would be the only icon in Icon in the UI and thus be an outlier and inconsistent. He also liked it but thought that it should probably be improved upon wile respecting the Blender UI standards. So yes - but it needs to work somehow differently. By the time it was already rejected, though.

And I understand that argument from a logical consistency standpoint but there never was a better solution and I’d rather Blender have more Icon-In-Icons in the future instead of just “nope next”.

1 Like

Wow… perfect. Thank you.

Thank you for the detailed workaround.
I’ve been trying to figure this out for the past hour or two and can’t get it to work; scripting is definitely not my area. I was adding your lines to the scripting area, and after hitting play Blender was just throwing up an error.

If I’m understanding you correctly, this will add a camera button to a shelf? Which will perform the lock/unlock operation?

I’ve been waiting for this since 2.9 beta (I believe) after getting that short taste of the beta camera lock icon. I’m pretty patient when it comes to request that I don’t know how to implement myself. It’s just that this was being discussed as something the BF wanted to implement sometime in the future and it’s been a couple of years now since then.

Thanks for the help.


I’ve never edited blender scripts inside blender, but I’m pretty sure you can do it this way if you needed. The place I’m putting it already knows what ‘view’ is, its towards the top of that section if you scroll up enough. If you are trying to put it somehwere else you might need

view = context.space_data

above the part I am highlighting in the video.

This sort of thing works for anything, can get confusing as far as what you have to point it at though. I usually just check other things that are already there and try to figure it out, but this can also help
https://docs.blender.org/api/current/index.html

5 Likes

OMG!!! Thank you, seriously.

I got this to work from watching your video clip. I’m fine with where the icon is located and how it looks, but most of all I love its function.

I’ve never saved a script in Blender to run at start up. What I did was: “Save Script” > “Save Start Up File”.
It works, but there may be a proper way(?)

*If anyone else comes across this, make sure developer extra in the preference tab is toggled or the first step in Icas’ video clip “Edit Source” will not be an option in the RMB menu.

Thanks again. I really do need to find the time to watch Dr. Sybren’s Blender Scripting for Beginners videos.

Tim

4 Likes

I wanted to note that the workaround of putting the camera icon on the workspace tool shelf is workspace dependent. Meaning, if you switch to something like the UV editor the camera will no longer be locked. Once you return to that original workspace the camera icon will still be locked.
This is similar to how the other icons on that shelf work. This can have it’s own benefit and comes in handy if moving between workspaces, but I would still enjoy something that is permanent across all workspaces.

Thanks
Tim

1 Like

Every workspace has it’s own camera setting (ie, workspace views aren’t synchronized in Blender), so it’s something I would expect.

To the bigger issue - love the fact that lcas offered the quick fix (i’m using it, tis awesome!) - but doesn’t solve the problem for the blender population at large, especially newer users.

2 Likes