2nd Mask (created after existing keyframe) gets broken handles #76872

Closed
opened 2020-05-19 06:34:08 +02:00 by Ian Hubert · 17 comments

System Information
Operating system: Windows 64 bit
Graphics card: GTX1080

Blender Version
Broken: every 2.8 version I've tried (2.80 - 2.83), and back through 2.70

Description of the thing

  • Open blender,
  • Open a tracking/masking workspace
  • Load in a movie clip

now what works / doesnt work:

  • GOOD: insert first spline (Add > Circle), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts)
  • GOOD: insert first spline (Add > Circle), insert keyframe ({key I}), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), go to next frame, insert second spline (Add > Circle), change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts)
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), go to next frame, insert second spline (Add > Circle), change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline (handles on second spline go nuts)

My assumption here is that inserting a shapekey with only the first spline present fills data in MaskLayerShape for that frame [but only data for points of the first spline].
Now if you add a second spline, data for its points are "missing" from MaskLayerShape.
BKE_mask_layer_evaluate_animation / BKE_mask_layer_shape_to_mask / mask_layer_shape_to_mask_point will just use random garbage in that case?

Original report (but this can be reproduced without autokeying, see above):

Hello! This is regarding auto-keyframing with masking :)

So, if you turn on auto keyframing in the masking workspace, and create your first mask, everything behaves as you'd expect (although you have to double click to "apply" the keyframe, which is admittedly unexpected).

But if you then create a SECOND mask with auto keyframing enabled, at some point all the points will warble into a weird shape (even though you haven't added keyframes), and it'll become mostly useless.

It's always the second mask created after "auto-keyframing" is turned on

Here's a quick video showing it:
https://youtu.be/OWEEhA_3njA

I attached a blend file and a small video file (the video file doesn't matter though- it happens with all I've tried- but they can't be packed into the .blend file)

Thank you!!

Exact steps for others to reproduce the error
Open blender,
Open a tracking/masking workspace
Load in a movie clip
Turn on "Auto Keyframing"
Create a mask, animate it.
Create another mask, and scrub through the timeline- it'll get all tangled.

2nd Mask Auto Keyframes.blend

Narrow_Column_Steam.mov

**System Information** Operating system: Windows 64 bit Graphics card: GTX1080 **Blender Version** Broken: every 2.8 version I've tried (2.80 - 2.83), and back through 2.70 **Description of the thing** - Open blender, - Open a tracking/masking workspace - Load in a movie clip now what works / doesnt work: - GOOD: insert first spline (`Add` > `Circle`), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts) - GOOD: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), go to next frame, insert second spline (`Add` > `Circle`), change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts) - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), go to next frame, insert second spline (`Add` > `Circle`), change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline (handles on second spline go nuts) ``` My assumption here is that inserting a shapekey with only the first spline present fills data in MaskLayerShape for that frame [but only data for points of the first spline]. Now if you add a second spline, data for its points are "missing" from MaskLayerShape. BKE_mask_layer_evaluate_animation / BKE_mask_layer_shape_to_mask / mask_layer_shape_to_mask_point will just use random garbage in that case? ``` Original report (but this can be reproduced without autokeying, see above): Hello! This is regarding auto-keyframing with masking :) So, if you turn on auto keyframing in the masking workspace, and create your first mask, everything behaves as you'd expect (although you have to double click to "apply" the keyframe, which is admittedly unexpected). But if you then create a SECOND mask with auto keyframing enabled, at some point all the points will warble into a weird shape (even though you haven't added keyframes), and it'll become mostly useless. It's always the second mask created after "auto-keyframing" is turned on Here's a quick video showing it: https://youtu.be/OWEEhA_3njA I attached a blend file and a small video file (the video file doesn't matter though- it happens with all I've tried- but they can't be packed into the .blend file) Thank you!! **Exact steps for others to reproduce the error** Open blender, Open a tracking/masking workspace Load in a movie clip Turn on "Auto Keyframing" Create a mask, animate it. Create another mask, and scrub through the timeline- it'll get all tangled. [2nd Mask Auto Keyframes.blend](https://archive.blender.org/developer/F8542341/2nd_Mask_Auto_Keyframes.blend) [Narrow_Column_Steam.mov](https://archive.blender.org/developer/F8542342/Narrow_Column_Steam.mov)
Author

Added subscriber: @mrdodobird

Added subscriber: @mrdodobird
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'
Member

Confirming on first sight.

Could it be that there is just an update missing?

What I mean is I think I can get it to be reliable if

  • I move points [keyframe is inserted, but some update is missing -- if I start using the timeline and move points again then this will end up getting unpredictable (probably inserting keys in places which dont correspond to what is displayed on screen)]
  • dont move the timeline yet
  • do something that properly tags updates [e.g. select some other points]
  • select my original points again, move timeline/points etc...

Looking into this.
@mrdodobird : in the meantime: can you confirm this is more reliable for you if you change selection after the autokeyframe has been inserted?

Confirming on first sight. Could it be that there is just an update missing? What I mean is I think I can get it to be reliable if - I move points [keyframe is inserted, but some update is missing -- if I start using the timeline and move points again then this will end up getting unpredictable (probably inserting keys in places which dont correspond to what is displayed on screen)] - dont move the timeline yet - do something that properly tags updates [e.g. select some other points] - select my original points again, move timeline/points etc... Looking into this. @mrdodobird : in the meantime: can you confirm this is more reliable for you if you change selection after the autokeyframe has been inserted?
Author

AH! Cool hey, thanks, Philipp!

So- I thought I had my head wrapped around this (this is my first bug, so I checked everything like crazy), but I found a couple things out.

1.) it doesn't have anything to do with auto-keyframing. After you add a mask with keyframes, the next mask will get the weird warbles.
2.) I canavoid the issue if I create a new mask layer and add the mask to that, (which is honestly a pretty reasonable workaround for most instances)

But also- if I'm understanding your suggestion right, I've done a few tests with it, in every order I can think of, and it doesn't seem like changing the selection makes any difference.

AH! Cool hey, thanks, Philipp! So- I thought I had my head wrapped around this (this is my first bug, so I checked everything like crazy), but I found a couple things out. 1.) it doesn't have anything to do with auto-keyframing. After you add a mask with keyframes, the next mask will get the weird warbles. 2.) I *can*avoid the issue if I create a new mask layer and add the mask to that, (which is honestly a pretty reasonable workaround for most instances) But also- if I'm understanding your suggestion right, I've done a few tests with it, in every order I can think of, and it doesn't seem like changing the selection makes any difference.

This issue was referenced by a8a6b3627a

This issue was referenced by a8a6b3627af4660bf6eac926176668438929b3c1
Member

Added subscriber: @Sergey

Added subscriber: @Sergey
Member

Youtube video seems to be private.

Ah, I think I can properly reproduce now (I was using the mask primitives and not using the handles)
If you add another shape and use the handles, these indeed are mangled.

Not sure if this is properly supported after all? [makes me thing of meshes/curves -- where adding geometry after doing shapekeys is not such a good idea as well...]

maybe @Sergey can comment?

Anyways, D7786: Fix autokeyframing masks not updating properly should still make masking experience with auto-keyframing more pleasant?

Youtube video seems to be private. Ah, I think I can properly reproduce now (I was using the mask primitives and not using the handles) If you add another shape and use the handles, these indeed are mangled. Not sure if this is properly supported after all? [makes me thing of meshes/curves -- where adding geometry after doing shapekeys is not such a good idea as well...] maybe @Sergey can comment? Anyways, [D7786: Fix autokeyframing masks not updating properly](https://archive.blender.org/developer/D7786) should still make masking experience with auto-keyframing more pleasant?
Member

In #76872#934599, @mrdodobird wrote:
AH! Cool hey, thanks, Philipp!

So- I thought I had my head wrapped around this (this is my first bug, so I checked everything like crazy), but I found a couple things out.

1.) it doesn't have anything to do with auto-keyframing. After you add a mask with keyframes, the next mask will get the weird warbles.
2.) I canavoid the issue if I create a new mask layer and add the mask to that, (which is honestly a pretty reasonable workaround for most instances)

But also- if I'm understanding your suggestion right, I've done a few tests with it, in every order I can think of, and it doesn't seem like changing the selection makes any difference.

Hi, we were typing at the same time:

  • yes, your issue is not related to autokeyframing, adding anything to a mask after it has keyframes will show this
  • changing selection would just make the mask update properly after the auto-keyframe has been inserted, so it doesnt hop into other places when scrubbing...
> In #76872#934599, @mrdodobird wrote: > AH! Cool hey, thanks, Philipp! > > So- I thought I had my head wrapped around this (this is my first bug, so I checked everything like crazy), but I found a couple things out. > > 1.) it doesn't have anything to do with auto-keyframing. After you add a mask with keyframes, the next mask will get the weird warbles. > 2.) I *can*avoid the issue if I create a new mask layer and add the mask to that, (which is honestly a pretty reasonable workaround for most instances) > > But also- if I'm understanding your suggestion right, I've done a few tests with it, in every order I can think of, and it doesn't seem like changing the selection makes any difference. Hi, we were typing at the same time: - yes, your issue is not related to autokeyframing, adding anything to a mask after it has keyframes will show this - changing selection would just make the mask update properly after the auto-keyframe has been inserted, so it doesnt hop into other places when scrubbing...
Author

Oh! sorry about that- the video is public now, though it sounds like you've already seen what it shows.

The additional "phantom keyframes" that appear on the second mask do appear to match up somewhat to the keyframes possessed by the first mask.

And yes! This would definitely make auto keyframing more pleasant!

Although on the subject of a pleasant rotoscoping experience (which can be a bit of a slog at the best of times), Sergey (hello! :) ) do you know why you still have to double click to add the keyframe if auto-keyframing is enabled? That's different from auto-keyframing behavior everywhere else in blender, and it's fairly confusing when you first start masking.

Oh! sorry about that- the video is public now, though it sounds like you've already seen what it shows. The additional "phantom keyframes" that appear on the second mask do appear to match up somewhat to the keyframes possessed by the first mask. And yes! This would definitely make auto keyframing more pleasant! Although on the subject of a pleasant rotoscoping experience (which can be a bit of a slog at the best of times), Sergey (hello! :) ) do you know why you still have to double click to add the keyframe if auto-keyframing is enabled? That's different from auto-keyframing behavior everywhere else in blender, and it's fairly confusing when you first start masking.
Member

Changing back to Report from Bug until we know if this is supposed to be supported...

Changing back to Report from Bug until we know if this is supposed to be supported...

@lichtwerk mask surely shouldn't be mangled after modifying it.
Could be missing DEG_id_update_tag call. How do i reproduce the issue with the attached file?

@lichtwerk mask surely shouldn't be mangled after modifying it. Could be missing `DEG_id_update_tag` call. How do i reproduce the issue with the attached file?
Member

I have this on the list for tomorrow to look at again

I have this on the list for tomorrow to look at again
Member

Changing the handle type seems to play an important part, animation of just the point positions seems to be fine.

@Sergey: To recap how this can be reproduced:

  • Open blender,
  • Open a tracking/masking workspace
  • Load in a movie clip

now what works / doesnt work:

  • GOOD: insert first spline (Add > Circle), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts)
  • GOOD: insert first spline (Add > Circle), insert keyframe ({key I}), insert second spline (Add > Circle) on the same frame, change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), go to next frame, insert second spline (Add > Circle), change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts)
  • FAIL: insert first spline (Add > Circle), insert keyframe ({key I}), go to next frame, insert second spline (Add > Circle), change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline (handles on second spline go nuts)

My assumption here is that inserting a shapekey with only the first spline present fills data in MaskLayerShape for that frame [but only data for points of the first spline].
Now if you add a second spline, data for its points are "missing" from MaskLayerShape.
BKE_mask_layer_evaluate_animation / BKE_mask_layer_shape_to_mask / mask_layer_shape_to_mask_point will just use random garbage in that case?

Not exactly sure why this is only a problem with handles (but maybe my analysis is also wrong).
This also seems to happen when adding a second spline (using {key CTRL LMB}), changing the handle type is not even necessary in that case.

Changing the handle type seems to play an important part, animation of just the point positions seems to be fine. @Sergey: To recap how this can be reproduced: - Open blender, - Open a tracking/masking workspace - Load in a movie clip now what works / doesnt work: - GOOD: insert first spline (`Add` > `Circle`), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts) - GOOD: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), insert second spline (`Add` > `Circle`) on the same frame, change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), go to next frame, insert second spline (`Add` > `Circle`), change handle type on one point of second spline from Auto to Aligned, scub timeline (handles on second spline go nuts) - FAIL: insert first spline (`Add` > `Circle`), insert keyframe ({key I}), go to next frame, insert second spline (`Add` > `Circle`), change handle type on one point of second spline from Auto to Aligned, insert keyframe ({key I}), scub timeline (handles on second spline go nuts) My *assumption* here is that inserting a shapekey with only the first spline present fills data in `MaskLayerShape` for that frame [but only data for points of the first spline]. Now if you add a second spline, data for its points are "missing" from MaskLayerShape. `BKE_mask_layer_evaluate_animation` / `BKE_mask_layer_shape_to_mask` / `mask_layer_shape_to_mask_point` will just use random garbage in that case? Not exactly sure why this is only a problem with handles (but maybe my analysis is also wrong). This also seems to happen when adding a second spline (using {key CTRL LMB}), changing the handle type is not even necessary in that case.
Philipp Oeser changed title from 2nd Mask Created After Auto-Keyframing Enabled gets Mystery Keyframes to 2nd Mask (created after existing keyframe) gets broken handles 2020-06-25 12:13:41 +02:00
Member

Will classify as bug for now.

Will classify as bug for now.

This issue was referenced by 2e7e13442c

This issue was referenced by 2e7e13442c914a4e9610def67eb199ab40f6b2b1

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Sergey Sharybin self-assigned this 2021-03-29 16:19:49 +02:00
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
4 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#76872
No description provided.