Fix #102737: Keyframe jump operator includes hidden curves in Graph Editor #108549

Merged
Christoph Lendenfeld merged 1 commits from ChrisLend/blender:fix_graph_keyframe_jump into blender-v3.6-release 2023-06-08 11:02:24 +02:00

The graph editor has the function to hide the display of FCurves and to only draw keyframes on selected curves.

Both options were not respected when executing the frame jump operator, meaning it would jump to potentially hidden keyframes.

This patch adds a new operator that is specific to the Graph Editor and that respects those features.

The only possible issue that could arise from this is a slight confusion for the user why they behave differently between editors. Especially with only the Graph Editor and the 3D view open. In general I think it's an improvement and follows the "you can only modify what you see" mantra in blender

Also
Resolves #97701


I had a look at changing the existing operator, but the keylist generation has no notion of where it is being called from, and IMO it shouldn't need to. So the logical conclusion was a more specific modifier in the GE.

The graph editor has the function to hide the display of FCurves and to only draw keyframes on selected curves. Both options were not respected when executing the frame jump operator, meaning it would jump to potentially hidden keyframes. This patch adds a new operator that is specific to the Graph Editor and that respects those features. The only possible issue that could arise from this is a slight confusion for the user why they behave differently between editors. Especially with only the Graph Editor and the 3D view open. In general I think it's an improvement and follows the "you can only modify what you see" mantra in blender Also Resolves #97701 ------ I had a look at changing the existing operator, but the keylist generation has no notion of where it is being called from, and IMO it shouldn't need to. So the logical conclusion was a more specific modifier in the GE.
Christoph Lendenfeld added the
Module
Animation & Rigging
label 2023-06-02 16:40:32 +02:00
Christoph Lendenfeld requested review from Sybren A. Stüvel 2023-06-02 17:03:32 +02:00
Sybren A. Stüvel approved these changes 2023-06-06 17:13:36 +02:00
Sybren A. Stüvel left a comment
Member

LGTM! Just a small request, can be done before landing.

LGTM! Just a small request, can be done before landing.
@ -3182,1 +3182,4 @@
static bool keyframe_jump_poll(bContext *C)
{
return ED_operator_screenactive_norender(C) && CTX_wm_area(C)->spacetype != SPACE_GRAPH;

Maybe add acomment that explains that there is another operator for this specifically for the graph editor.

Maybe add acomment that explains that there is another operator for this specifically for the graph editor.
Christoph Lendenfeld force-pushed fix_graph_keyframe_jump from fd01f0bf21 to 1279787f56 2023-06-08 10:41:08 +02:00 Compare
Christoph Lendenfeld changed title from Fix #102737: Keyframe jump operator includes hidden curves in Graph Editor to Fix #102737: Keyframe jump operator includes hidden curves in Graph Editor 2023-06-08 10:41:09 +02:00
Christoph Lendenfeld changed target branch from main to blender-v3.6-release 2023-06-08 10:41:11 +02:00
Christoph Lendenfeld merged commit 2387290e4f into blender-v3.6-release 2023-06-08 11:02:24 +02:00
Christoph Lendenfeld deleted branch fix_graph_keyframe_jump 2023-06-08 11:02:30 +02:00
First-time contributor

The new graph.keyframe_jump is working incorrectly in NLA tweak strips actions mode with pinned on and the strip has frame start offset or time scale.

The operator jumps to the keyframes of the source action instead of the pinned time remapped keyframes.

screen.keyframe_jump works as expected, but not this new graph.keyframe_jump

Steps to reproduce

  1. Open the attached "graph.keyframe_jump_NLA-test.blend"
  2. With the "Cube" object selected and the NLA strip "CubeAction" selected in the NLA editor, press 'Tab' to enter tweak strip actions mode
  3. With the mouse over Graph Editor, press the default 'up' or 'down' arrow keys to jump to next or previous keyframes.
The new graph.keyframe_jump is working incorrectly in NLA tweak strips actions mode with pinned on and the strip has frame start offset or time scale. The operator jumps to the keyframes of the source action instead of the pinned time remapped keyframes. screen.keyframe_jump works as expected, but not this new graph.keyframe_jump **Steps to reproduce** 1. Open the attached "graph.keyframe_jump_NLA-test.blend" 2. With the "Cube" object selected and the NLA strip "CubeAction" selected in the NLA editor, press 'Tab' to enter tweak strip actions mode 3. With the mouse over Graph Editor, press the default 'up' or 'down' arrow keys to jump to next or previous keyframes.
Author
Member

@Tajino thanks for letting us know. In the future please make a new bug report, this makes it easier for us to track
I made on now #110789: Keyframe jump operator in the Graph Editor does not respect NLA offset

@Tajino thanks for letting us know. In the future please make a new bug report, this makes it easier for us to track I made on now [#110789: Keyframe jump operator in the Graph Editor does not respect NLA offset](https://projects.blender.org/blender/blender/issues/110789)
Sign in to join this conversation.
No Reviewers
3 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: blender/blender#108549
No description provided.