Animation: Move Graph Editor settings to User Preferences #104532

Merged
Christoph Lendenfeld merged 14 commits from ChrisLend/blender:user_pref_only_selected_keys into main 2023-03-09 14:15:36 +01:00

Move two settings that were previously in the "View" menu of the Graph Editor into User Preferences.

It has been mentioned in the meeting by Luciano Muñoz Sessarego that it would be good to move that to the preferences so you can set it once and then forget about it.

The Settings moved are:

Only Selected Curve Keyframes
Use High Quality Display

before
before

after
image


archived phabricator patch

https://archive.blender.org/developer/D17126

Move two settings that were previously in the "View" menu of the Graph Editor into User Preferences. It has been mentioned in the meeting by Luciano Muñoz Sessarego that it would be good to move that to the preferences so you can set it once and then forget about it. The Settings moved are: Only Selected Curve Keyframes Use High Quality Display before ![before](https://projects.blender.org/attachments/7e6837b9-c1fd-4529-aa1a-014c852402de) after ![image](/attachments/ce1f6a1f-496a-44a8-9d07-59b7a3e8040a) ----- archived phabricator patch https://archive.blender.org/developer/D17126
Christoph Lendenfeld added the
Module
Animation & Rigging
label 2023-02-09 17:58:14 +01:00
Christoph Lendenfeld added 3 commits 2023-02-09 17:58:16 +01:00
Christoph Lendenfeld requested review from Sybren A. Stüvel 2023-02-09 18:01:19 +01:00
Christoph Lendenfeld requested review from Luciano Muñoz Sessarego 2023-02-10 12:07:03 +01:00
Brecht Van Lommel added this to the Animation & Rigging project 2023-02-13 09:13:10 +01:00
Sybren A. Stüvel approved these changes 2023-02-14 15:12:29 +01:00
Sybren A. Stüvel left a comment
Member

The code LGTM. I'll defer the final verdict to @LucianoMunoz (or some other animator if they want to step in).

The code LGTM. I'll defer the final verdict to @LucianoMunoz (or some other animator if they want to step in).
First-time contributor

Hey thanks for trying to address this issue,

The thing is you only need to move the "only selected curve keyframes" to the preferences and keep "only selected keyframe handles" in the original menu.
Here is why the first one is a permanent option that users either like or not on a forever basis, as in way of working, while the latter is more of a sporadic option that users will want to turn on and off depending on what their doing in the moment just like turning on and off a particular curve.

On the other hand "use high quality display" is an other good candidate to move to preferences as per the same reasons.

Hope that makes sense.

Hey thanks for trying to address this issue, The thing is you only need to move the "only selected curve keyframes" to the preferences and keep "only selected keyframe handles" in the original menu. Here is why the first one is a permanent option that users either like or not on a forever basis, as in way of working, while the latter is more of a sporadic option that users will want to turn on and off depending on what their doing in the moment just like turning on and off a particular curve. On the other hand "use high quality display" is an other good candidate to move to preferences as per the same reasons. Hope that makes sense.
Christoph Lendenfeld added 3 commits 2023-02-16 17:54:50 +01:00

The Settings moved are:

Only Selected Curve Keyframes

There's a bit of leftover plural in the title & description. Those can be left as-is, when we follow @Looch 's suggestion to also move "use high quality display" to the preferences.

> The Settings moved are: > > Only Selected Curve Keyframes There's a bit of leftover plural in the title & description. Those can be left as-is, when we follow @Looch 's suggestion to also move "use high quality display" to the preferences.
Christoph Lendenfeld added 2 commits 2023-02-23 11:40:30 +01:00
Christoph Lendenfeld added 1 commit 2023-02-23 11:41:27 +01:00
Author
Member

@dr.sybren I also moved high quality drawing into user prefs in this PR

It should be enabled by default, but I am unsure if that is working. I can reset it to default which enables it. But starting my Blender it is always disabled.
I am not sure if that is just because i've been developing and it is now saved as off, or if new user properties are always off

@dr.sybren I also moved high quality drawing into user prefs in this PR It should be enabled by default, but I am unsure if that is working. I can reset it to default which enables it. But starting my Blender it is always disabled. I am not sure if that is just because i've been developing and it is now saved as off, or if new user properties are always off
Christoph Lendenfeld requested review from Sybren A. Stüvel 2023-02-24 16:16:08 +01:00
Sybren A. Stüvel requested changes 2023-02-27 17:41:17 +01:00
Sybren A. Stüvel left a comment
Member

You're almost there. The last step is to add versioning code for the user preferences. The thing is that new properties apparently don't get set to the default value automatically. This needs a bit of code in blo_do_versions_userdef(), in versioning_userdef.c.

The defaults are used when you start Blender with --factory-startup, though, so they need to be set anyway.

You're almost there. The last step is to add versioning code for the user preferences. The thing is that new properties apparently don't get set to the default value automatically. This needs a bit of code in `blo_do_versions_userdef()`, in `versioning_userdef.c`. The defaults are used when you start Blender with `--factory-startup`, though, so they need to be set anyway.
Christoph Lendenfeld added 2 commits 2023-03-02 13:28:06 +01:00
Christoph Lendenfeld requested review from Sybren A. Stüvel 2023-03-02 13:28:12 +01:00
Author
Member

I've added the versioning code, assuming it goes into the curly braces at the bottom

I've added the versioning code, assuming it goes into the curly braces at the bottom
Sybren A. Stüvel approved these changes 2023-03-03 15:19:37 +01:00
Sybren A. Stüvel left a comment
Member

I've added the versioning code, assuming it goes into the curly braces at the bottom

Yup, that's where it goes until there is a sub-version bump. In this case we have to do that bump, since there is no other way. Sometimes you can use DNA_struct_elem_find() to see if the struct already a specific field when it was saved or not. Since this doesn't add any new fields, that's not something we can do, so the only way is to bump. Before you land the PR:

  • increase BLENDER_FILE_SUBVERSION by one, and
  • wrap userdef->animation_flag |= USER_ANIM_HIGH_QUALITY_DRAWING; with an if (!USER_VERSION_ATLEAST(306, 2)) { and move it above that "new stuff goes here" block.
> I've added the versioning code, assuming it goes into the curly braces at the bottom Yup, that's where it goes until there is a sub-version bump. In this case we have to do that bump, since there is no other way. Sometimes you can use `DNA_struct_elem_find()` to see if the struct already a specific field when it was saved or not. Since this doesn't add any new fields, that's not something we can do, so the only way is to bump. Before you land the PR: - increase `BLENDER_FILE_SUBVERSION` by one, and - wrap `userdef->animation_flag |= USER_ANIM_HIGH_QUALITY_DRAWING;` with an `if (!USER_VERSION_ATLEAST(306, 2)) {` and move it above that "new stuff goes here" block.
Pablo Vazquez reviewed 2023-03-03 15:28:49 +01:00
@ -5173,0 +5183,4 @@
prop = RNA_def_property(srna, "fcurve_high_quality_drawing", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "animation_flag", USER_ANIM_HIGH_QUALITY_DRAWING);
RNA_def_property_ui_text(prop,
"FCurve High Quality Display",
Member

FCurve is missing a hyphen, it's F-Curve.

`FCurve` is missing a hyphen, it's `F-Curve`.
Author
Member

fixed it, thanks :)

fixed it, thanks :)
pablovazquez marked this conversation as resolved
Christoph Lendenfeld added 1 commit 2023-03-03 16:20:03 +01:00
Christoph Lendenfeld added 1 commit 2023-03-03 16:44:09 +01:00
Christoph Lendenfeld requested review from Pablo Vazquez 2023-03-03 17:07:10 +01:00
Pablo Vazquez approved these changes 2023-03-07 15:42:44 +01:00
Christoph Lendenfeld added 1 commit 2023-03-09 10:28:32 +01:00
Author
Member

@dr.sybren can you have a quick look over the versioning code to check if I did the changes correctly

@dr.sybren can you have a quick look over the versioning code to check if I did the changes correctly

Yeah that looks good!

Yeah that looks good!
Christoph Lendenfeld merged commit 3b900048f1 into main 2023-03-09 14:15:36 +01:00
Christoph Lendenfeld deleted branch user_pref_only_selected_keys 2023-03-09 14:15:37 +01:00
Sybren A. Stüvel removed this from the Animation & Rigging project 2023-03-14 10:51:09 +01:00
First-time contributor

Sorry I'm late to the party but just to mention I'm actually constantly toggling "only selected curve keyframes" on and off, in my quick fav, as I'm working on facial mocap and have to deal with thousands of keyframes on a hundred channels at once.

I will have to constantly select all channels now if I want to interact with them when doing keyframe anim, instead of just toggling the option off in my quick fav.

It would seem much more logical to me to "sacrifice" the "only selected keyframe handles" from the menu and send it to the pref if needed, as taht's something you're much less likely to toggle on and off constantly. But overall sending anything ot the pref is just reducing flexibilty and speed, it's one very handy feature less...

Sorry I'm late to the party but just to mention I'm actually constantly toggling "only selected curve keyframes" on and off, in my quick fav, as I'm working on facial mocap and have to deal with thousands of keyframes on a hundred channels at once. I will have to constantly select all channels now if I want to interact with them when doing keyframe anim, instead of just toggling the option off in my quick fav. It would seem much more logical to me to "sacrifice" the "only selected keyframe handles" from the menu and send it to the pref if needed, as taht's something you're much less likely to toggle on and off constantly. But overall sending anything ot the pref is just reducing flexibilty and speed, it's one very handy feature less...
Author
Member

@loicbramoulle Sorry about that. That use case didn't come up when this change was discussed.
The reason for the change was that animators were annoyed that they had to change it every time they opened a new file.

I just talked with @BClark and he mentioned he uses this in a similar way as well. So we need to find a proper solution to support both use cases.

In the meantime I will create a quick addon that toggles the setting in your user prefs so you can have it readily available. It should even be possible to run that toggle from a quick favourites menu

@loicbramoulle Sorry about that. That use case didn't come up when this change was discussed. The reason for the change was that animators were annoyed that they had to change it every time they opened a new file. I just talked with @BClark and he mentioned he uses this in a similar way as well. So we need to find a proper solution to support both use cases. In the meantime I will create a quick addon that toggles the setting in your user prefs so you can have it readily available. It should even be possible to run that toggle from a quick favourites menu
First-time contributor

Thanks a lot @ChrisLend
Ow I see, having it On in their default file wasn't a solution ? if they opened other people aniamtion file maybe that was the annoyance ?

Not sure if that would make sense but the preference option could be to "force always showing all channel/curve keys", or "allow channel key/curves visibility toggle" or basically something that enable this toggle option in the view menu. if that makes sense it might accommodate both usecase, but not sure it's conventional.

Thanks again.

Thanks a lot @ChrisLend Ow I see, having it On in their default file wasn't a solution ? if they opened other people aniamtion file maybe that was the annoyance ? Not sure if that would make sense but the preference option could be to "force always showing all channel/curve keys", or "allow channel key/curves visibility toggle" or basically something that enable this toggle option in the view menu. if that makes sense it might accommodate both usecase, but not sure it's conventional. Thanks again.
Author
Member

@loicbramoulle here is a small addon that adds the toggle back to the menu. I've also made a toggle operator because Blender doesn't allow to add the property from the user preferences to the quick favorites.

However I'd like to follow up on that and understand your workflow better. I get the feeling this setting is being used as a crutch when there could be a better solution. Do you mind getting in contact with me on blender.chat or via email (chris.lenden@gmail.com)

If there is a better solution it might benefit everyone

@loicbramoulle here is a small addon that adds the toggle back to the menu. I've also made a toggle operator because Blender doesn't allow to add the property from the user preferences to the quick favorites. However I'd like to follow up on that and understand your workflow better. I get the feeling this setting is being used as a crutch when there could be a better solution. Do you mind getting in contact with me on blender.chat or via email (chris.lenden@gmail.com) If there is a better solution it might benefit everyone
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
5 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#104532
No description provided.