Implement motion path drawing code in draw engine #54991

Closed
opened 2018-05-07 17:26:58 +02:00 by Joshua Leung · 17 comments
Member

Motion path drawing code (drawanimviz.c) is not currently implemented in 2.8, meaning that old files with motion paths and/or files where motionpaths have been freshly calculated do not show up.

Branch / Current Code: tmp-b28-motionpath-drawing

Design Notes:

  • This should work as an overlay (visible in the overlays popover), so that it can be turned on/off independent of other stuff we draw in the viewport. It should not be tied to manipulator/relationship line visibility.
  • Motion paths work with both objects and bones. They can either be defined on Object Level (e.g. ob->mpath), or Bone Level (e.g. pchan->mpath)
  • The old drawing methods use immediate mode. Could/should be optimised.
  • Appearance could be updated a bit - for example, thicker/nicer line quality + shading, different ways of visualising the keyframe positions (e.g. with lines perpendicular to path - similar to what animators use for timing charts - [ - ], [http:*www.brianlemay.com/Pages/animationschool/animation/lipsyncbook/timingcharts.html | 2 ]
Motion path drawing code (drawanimviz.c) is not currently implemented in 2.8, meaning that old files with motion paths and/or files where motionpaths have been freshly calculated do not show up. **Branch / Current Code**: `tmp-b28-motionpath-drawing` **Design Notes:** * This should work as an overlay (visible in the overlays popover), so that it can be turned on/off independent of other stuff we draw in the viewport. It should not be tied to manipulator/relationship line visibility. * Motion paths work with both objects and bones. They can either be defined on Object Level (e.g. ob->mpath), or Bone Level (e.g. pchan->mpath) * The old drawing methods use immediate mode. Could/should be optimised. * Appearance could be updated a bit - for example, thicker/nicer line quality + shading, different ways of visualising the keyframe positions (e.g. with lines perpendicular to path - similar to what animators use for timing charts - [ - [x]], [[http:*www.brianlemay.com/Pages/animationschool/animation/lipsyncbook/timingcharts.html | 2](http:*profspevack.com/archive/animation/course_cal/week05/week05.html) ]
Author
Member

Added subscriber: @JoshuaLeung

Added subscriber: @JoshuaLeung
Author
Member

Added subscriber: @Jeroen-Bakker

Added subscriber: @Jeroen-Bakker
Joshua Leung self-assigned this 2018-05-14 13:37:07 +02:00

Added subscriber: @LucianoMunoz

Added subscriber: @LucianoMunoz
Joshua Leung removed their assignment 2018-05-22 12:09:10 +02:00
Clément Foucault was assigned by Joshua Leung 2018-05-22 12:09:10 +02:00
Author
Member

Added subscriber: @fclem

Added subscriber: @fclem
Author
Member

Offloading to @fclem who can probably do this faster, while I deal with nasty Copy-on-Write issues.

Current WIP code can be found in the tmp-b28-motionpath-drawing branch.

Offloading to @fclem who can probably do this faster, while I deal with nasty Copy-on-Write issues. Current WIP code can be found in the `tmp-b28-motionpath-drawing` branch.

Please consider an option to offset the motion path!, example, i create a motion path on the head bone but i want to offset it to the forehead, or to the tip of the ear (which are directly moved by the head joing)

Please consider an option to offset the motion path!, example, i create a motion path on the head bone but i want to offset it to the forehead, or to the tip of the ear (which are directly moved by the head joing)
Author
Member

@LucianoMunoz That is a separate topic - Calculation of motion paths is not the same as the drawing code (which this task focusses on restoring).

Regarding what you're talking about - we have been discussing ideas for allowing calculation of paths for arbitrary geometry points instead of just objects/bones (e.g. using the derived center-of-gravity for a body part for instance). But, again, that's a separate topic, to be tackled separately/later once we get back basic functionality (with maybe a slight cosmetic upgrade).

@LucianoMunoz That is a separate topic - Calculation of motion paths is not the same as the drawing code (which this task focusses on restoring). Regarding what you're talking about - we have been discussing ideas for allowing calculation of paths for arbitrary geometry points instead of just objects/bones (e.g. using the derived center-of-gravity for a body part for instance). But, again, that's a separate topic, to be tackled separately/later once we get back basic functionality (with maybe a slight cosmetic upgrade).

oh cool, sorry for spamming the wrong thread, if you want to point me in the right direction it Id be happy to contribute :)

oh cool, sorry for spamming the wrong thread, if you want to point me in the right direction it Id be happy to contribute :)

in regards to drawing, maybe there could be an option to randomize colors for them, so each new path gets a different color, though they should probably go in order, Ie, 1 gets red, the second one gets green, the third one gets blue and so on, much easier to see, and the thicknes definitelly should be like what in 2.79 wa 2 px or so.

in regards to drawing, maybe there could be an option to randomize colors for them, so each new path gets a different color, though they should probably go in order, Ie, 1 gets red, the second one gets green, the third one gets blue and so on, much easier to see, and the thicknes definitelly should be like what in 2.79 wa 2 px or so.

Added subscriber: @DanielPaul

Added subscriber: @DanielPaul

Im not sure if i overlooked something in the description above,
but will the motion paths be calculated automatically.
So we dont have to set the framerange, only a max and min frame value would be nice.

Im not sure how dificult this is, but it would be a nice way to diplay the motion path.
Also the tangent editing is nice.
Animationcurve_01.gif

Im not sure if i overlooked something in the description above, but will the motion paths be calculated automatically. So we dont have to set the framerange, only a max and min frame value would be nice. Im not sure how dificult this is, but it would be a nice way to diplay the motion path. Also the tangent editing is nice. ![Animationcurve_01.gif](https://archive.blender.org/developer/F3489132/Animationcurve_01.gif)
Author
Member

@DanielPaul

  • Auto calculation is a separate topic - it's not related to the drawing.
  • The main interesting features of that mockup are the explicit display of the start/end frames. Otherwise, it's actually pretty much just the standard display
  • "Tangent editing" or just general motion path editing is actually a lot harder than it looks - especially in everything other than the most basic case. Unfortunately, you can't just support that simple case, as people will want the others too. Anyway, again this is separate from the issue of just getting drawing code working
@DanielPaul - Auto calculation is a separate topic - it's not related to the drawing. - The main interesting features of that mockup are the explicit display of the start/end frames. Otherwise, it's actually pretty much just the standard display - "Tangent editing" or just general motion path editing is actually a lot harder than it looks - especially in everything other than the most basic case. Unfortunately, you can't just support that simple case, as people will want the others too. Anyway, again this is separate from the issue of just getting drawing code working

@JoshuaLeung

Is there a reason not to tag the baked motion path verts if there are on a keyframe? It would simplify the whole drawing a lot.
Also I don't see the point of showing synced keyframe marker but at the baked position.

@JoshuaLeung Is there a reason not to tag the baked motion path verts if there are on a keyframe? It would simplify the whole drawing a lot. Also I don't see the point of showing synced keyframe marker but at the baked position.

its important to show the keyframes in the motion path of the selected object, which is not necesarilly the object from which the motion path is calculated.

its important to show the keyframes in the motion path of the selected object, which is not necesarilly the object from which the motion path is calculated.

@LucianoMunoz
I don't understand. Keyframes are only showed when there is keys are on the motion path, which is baked from an object/bone.
I don't even think that's possible to show the selected object keyframe on another path in 2.7.

Also for the record, I talked with @JoshuaLeung IRL and he told me it was ok to bake the keyframes into the motionpath verts.

@LucianoMunoz I don't understand. Keyframes are only showed when there is keys are on the motion path, which is baked from an object/bone. I don't even think that's possible to show the selected object keyframe on another path in 2.7. Also for the record, I talked with @JoshuaLeung IRL and he told me it was ok to bake the keyframes into the motionpath verts.

that is accurate. in 2.7 it doesnt work like this, but this isnt useful at all, as an animator you want to see in the path the keyframes of the currently selected object that affects it,
example: the path is set to the head control, but i have the hip selected, the path should show the keys of the hip, because that´s what im modifiying that will ultimately affect the path because of the hierarchy (you should try to confirm with hjalti, he knows exactly what im talking about)

that is accurate. in 2.7 it doesnt work like this, but this isnt useful at all, as an animator you want to see in the path the keyframes of the currently selected object that affects it, example: the path is set to the head control, but i have the hip selected, the path should show the keys of the hip, because that´s what im modifiying that will ultimately affect the path because of the hierarchy (you should try to confirm with hjalti, he knows exactly what im talking about)

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
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#54991
No description provided.