Search Unity

Official PlayableGraph Visualizer package (in preview)

Discussion in 'Animation' started by Deleted User, Dec 21, 2018.

  1. Deleted User

    Deleted User

    Guest

    Hi all!

    I took some time during my holidays to make a package out of the graph-visualizer GitHub repository (it was something I wanted to do for a long time! ;) ).

    For those who don't know yet what this project is, it is a tool that allow to visualize the Playable graphs that are running in the current scene. And you get something like that:

    PlayableGraph Visualizer - screenshot 03.png

    To install the package:
    • Open the Package Manager window: Window > Package Manager
    • Show preview packages: Advanced > Show preview packages
    • Search for "playable"
    • Select the "PlayableGraph Visualizer" package
    • Click on the "Install" button
    Thank you!

    _________________

    Edit:
    • 2019-01-30: New release v0.2.0-preview.2
    • 2019-01-03: Package has been whitelisted; it is now available in Package Manager
     
    Last edited by a moderator: Jan 30, 2019
    bupt_yyf and AndrewKaninchen like this.
  2. florianhanke

    florianhanke

    Joined:
    Jun 8, 2018
    Posts:
    426
    Hi Romain,

    It works very well, thanks! If you have specific questions, please let us know.

    One thing I was wondering about was whether the Window menu option should be in the Analysis submenu so it does not clutter up the top-level Window menu.

    Cheers!
     
  3. sunrisebacon

    sunrisebacon

    Joined:
    Jul 15, 2017
    Posts:
    16
    I'm very new to the Playables API but as far as I can tell it works.

    I've only used it with the Animator and I have a very hard time translating (in my head) the Animator graph to what the visualizer is displaying. It seems very abstract and doesn't really match the flow of animations. At least not in an obvious way.
    The only concrete information I can see is the name of the clip that is currently playing and only if I click the active Animation Clip.

    Otherwise, I second Florian's point about putting the visualizer it in the Analytics submenu.
     
  4. Deleted User

    Deleted User

    Guest

    Hello!

    Thanks for the feedbacks ;)
    I'll change the namespace, but I'll need to bump the major version (since it breaks the API)

    I agree for the menu, I'll find another place to put it (probably Analysis as you said, but I'll need to check with our UX team).

    As for the graph representation, the clips (on the right) are played and blended through the mix nodes going toward the root (on the left).
     
  5. Deleted User

    Deleted User

    Guest

    The package preview has been whitelisted, so now it's available directly from the Package Manager UI (if "Advanced > Show preview packages" is checked).
    upload_2019-1-3_17-52-20.png
    This is a first preview with exactly the same content as before (no API changes, and no Menu changes as discussed above).
     
    Lars-Steenhoff likes this.
  6. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,338
    I'll give it a spin.

    I've had the visualizer in our project since it launched, and it's been pretty useful, so being able to delete it and have it as a package would be useful. Looking at the repo, I realize that I'm miles behind, and it's got a bunch of improvements semi-recently, so I'm very happy about this.

    Do you know if there's any progress on plans for having packages include #defines? I've got some animation plugins that I've included the visualizer in. I'd like to remove the visualizer from them, and instead wrap the visualizer integration in #if PlayableGraphVisualizer, but afaik that's not possible right now?
     
  7. Deleted User

    Deleted User

    Guest

    @Baste A feature that looks like what you want landed in 2019.1. I've asked the devs for more information, I'll get back to you.
     
    Baste likes this.
  8. Deleted User

    Deleted User

    Guest

    @Baste I'll need to do some test, but it seems to be doable (might break the API though, since this feature appeared in 2019.1).
     
    Baste and Lars-Steenhoff like this.
  9. Deleted User

    Deleted User

    Guest

    New v0.2.0-preview.2 !

    Changes are:
    • Moved from MIT to UCL license (it's a legal prerequisite for a package made by Unity)
    • Moved menu entry under "Window > Analysis" (as @florianhanke proposed)
     
    florianhanke likes this.
  10. Deleted User

    Deleted User

    Guest

    It actually goes both ways, so there is no best direction to represent the graph.

    When preparing the graph, information (such as time) is propagated from the root, on the left, to the leaves, on the right.
    But when processing the graph, nodes (such as AnimationClipPlayable) get executed from the leaves, on the right, to the root, on the left.
     
  11. Deleted User

    Deleted User

    Guest

    All the Playable nodes have a prepare and a process pass. You can see the Animation C# Job for more information: https://blogs.unity3d.com/2018/08/27/animation-c-jobs/

    But there is no right or wrong way of showing the graph, it could have been top-down as well. I understand it might feel strange to you (maybe you're used to shader graphs?), but in the end it's just a matter of getting used to it.

    About your issue, I'm not sure I understand it well. It should be possible to animate material properties, but some properties can't be animated, try to animate them in the AnimationWindow and see which properties can be animated and which can't.

    When you say "it seems like there's no way to make AnimationClips for Playables", I don't understand. Especially the "make" part. Playable is not meant to make anything, but to process data. The AnimationClipPlayable is the node that allows to play an AnimationClip.

    Timeline uses the Playable as a back-end, and basically brings scheduling to the Playable API; Timeline allows to schedule clips/events over time.
     
    twobob likes this.
  12. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,338
    The Playables system plays exactly the same animation clips as the Animation component and the Animator with an AnimatorController It's just a different (more flexible, more complex) way of playing them.

    To round-trip, you need to provide the animation clips to the animation window using the IAnimationClipSource. The SimpleAnimation component does this.


    Timeline is a system for movies and uninteractive cutscenes that's driven by Playables, and is somewhat unrelated to animating single characters or objects. I mean, you can animate a single object in a timeline, but that's probably way overkill.
     
    Deleted User likes this.
  13. Deleted User

    Deleted User

    Guest

    That's it, Playable is merely a back-end for Timeline. But it can do more than being a back-end just for Timeline, it is used for instance by SimpleAnimation, and the Runtime Rigging package.

    And instead of making it a blackbox, we exposed the API for those who would like to yolo it ;)
     
    Last edited by a moderator: Mar 7, 2019
    twobob and jrumps like this.
  14. Kybernetik

    Kybernetik

    Joined:
    Jan 3, 2013
    Posts:
    2,570
    I just gave it a go and found that the graph selection dropdown only ever shows one "[Unnamed]" graph, even if there are multiple graphs without a name.
     
  15. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,788
    @RomainFailliot is the Runtime Rigging a new stuff? i never heard about it, how come it never being announced? for me personally those stuff are very powerfull for extending animation.
     
  16. Deleted User

    Deleted User

    Guest

    @SilentSin: I'll have a look at it. I don't think it's supposed to happen, but you can still name your graphs, that's the best way to fix your problem (otherwise you would just have a bunch of [Unnamed] graphs, I'm pretty sure that won't be more useful ;) )

    @Reanimate_L: It has just been presented at GDC 2019, it's a fairly new feature and still experimental. Though it's already pretty powerful!
     
    Reanimate_L likes this.
  17. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,788
    I see well that is a good news, as some one who always using controller and constraint for rigging this will help a lot. I notice the constraint are still limited ,i understand it's still new feature which i hope more constraint will be added in the future. Also is there a plan to create a programmable constraint in the future (with the new visual script editor maybe)? this way we can setup/create/combine constraint as we want. That would give us more flexibility and power?
    And is this runtime rigging are part of the C# job animation system? i mean like we starting to get multiple animation system any plan to merge them to centralize the API?
     
  18. Deleted User

    Deleted User

    Guest

    Hehe, yes to all that actually!
    Animation rigging is based on the new C# animation job and thanks to that, you can already create your own constraints, it's been designed with that in mind. And we'll provide a library of constraints starting with IK, offset, and a few other..
     
    Reanimate_L likes this.
  19. epmsimard

    epmsimard

    Joined:
    Apr 17, 2019
    Posts:
    1
    Hi @RomainFailliot,

    I'm testing the visualizer for the first time trying to see how it would translate if I wanted to provide building blocks to my animators and let them create a graph but it seems to be oriented only toward showing the data flow and not letting you create one of your own (outside of Animator). Any plans there?

    Interestingly it's showing me the following when I create a new animator graph with only an animation clip in it and double click on the clip.
    upload_2019-4-17_13-15-28.png

    It's hard to find the link between each node and what we see in Animator when the nodes show the node type but don't have the node name. I understand what the first few nodes refer to but I'm puzzled to the second set of Animation Mixer, Animation Clip and the presence of Animation Pose at each levels.
     
    twobob likes this.
  20. Kybernetik

    Kybernetik

    Joined:
    Jan 3, 2013
    Posts:
    2,570
    The visualiser really doesn't seem to help understand what the AnimatorController does internally. As far as I can tell, it only connects the playables of the current state and the one being transitioned towards at any given time because that's all the visualiser shows. So it's most likely keeping the playables for all the other states disconnected until needed.

    It's also a bit strange if you watch what happens when you have the active state (the top clip) selected when it fades out. It moves your selection down to the other clip and the inspector shows the clip as "none". So I'm not sure if that's just a minor bug in the way the visualiser keeps track of the selected node or the controller is actually changing the playable's clip (which isn't possible with the API we have access to as far as I know).

    I have no idea what the AnimationPose nodes are either. They just show up as Playable for me (in Unity 2018.1).

    I also tried to fiddle around with the graph a bit using scripts but found that everything is protected from tampering (gives an error if you try) except for the final output, but swapping that to something else does nothing because it just gets set straight back. I'd actually like to be able to do the same to protect my own graphs in Animancer Lite, but that doesn't seem to be exposed by the API either (there are methods for CanChangeInputs, CanDestroy, and CanSetWeights, but they are undocumented and I haven't found a way to set those flags).
     
  21. Justin_Larrabee

    Justin_Larrabee

    Joined:
    Apr 24, 2018
    Posts:
    106
    Are there any updates planned for this tool? It's completely unusable on graphs of a non-trivial size. At the very least having zoom and pan is necessary.
     
  22. Phi79

    Phi79

    Joined:
    Nov 30, 2014
    Posts:
    5
    I have been testing the PlayableGraph Visualizer and found that it is NOT what I have original expected!

    I would expect the "Visualizer" should at least enable us to "see" what animation clip is/will play rather than just a Round Square Box label as "Animation Clip"...Just some text messages saying the status of animation is not good enough. A better visualizing is we can actually see the animation playing (like a video player) with a vertical line on a timeline to tell us the current position of the animation that is playing. Or somethings like the preview available in Unity's inspector to examine the actual animation.

    Otherwise, when there are a few Animation Clips and Poses lying around in the screen, we actually don't know which is which animation is playing! You can refer to something like the Shader Editor's visualization or Blueprint in Unreal Engine or many other "visualizer" tools, they can usually display in actual "graphic" about the state of each processing - Can we do the same thing for the Animation Mixer, rather than just a box with a label?
     
    Last edited: Mar 2, 2020
  23. pdinklag

    pdinklag

    Joined:
    Jan 24, 2017
    Posts:
    154
    Any updates on this package?

    The latest version is 1.5 years old, but it's still in preview. Now in Unity 2020.1, I get a warning about using preview packages - this is the only one. Despite the mentioned issues in this thread, it's a useful tool.

    The OP of this thread is a "Deleted User", so I guess whoever was working on it is no longer part of the Unity team? Is anybody even responsible for this, does any Unity team member have this on the map?
     
    mandisaw and kyuskoj like this.
  24. Justin_Larrabee

    Justin_Larrabee

    Joined:
    Apr 24, 2018
    Posts:
    106
    Yea I've been working under the assumption that this tool is dead, and any future tools will be made specifically for DOTS (fine with me, we use it).
     
  25. wang37921

    wang37921

    Joined:
    Aug 1, 2014
    Posts:
    102
    i cannt found it in Unity 2020.1's package manager
     
    PaulaJulija likes this.
  26. _slash_

    _slash_

    Joined:
    Mar 26, 2013
    Posts:
    37
  27. zhuchun

    zhuchun

    Joined:
    Aug 11, 2012
    Posts:
    433
    mandisaw likes this.
  28. razzraziel

    razzraziel

    Joined:
    Sep 13, 2018
    Posts:
    396
    Was looking for this, thanks. Even tried a few variations like .playablegraphvisualizer, .playablegraph, .graph...
     
    Last edited: Sep 18, 2022
  29. Zawaseinlove

    Zawaseinlove

    Joined:
    Jun 25, 2022
    Posts:
    28
    I have the same problem,I creat many playables,but the dropDown only show one “Unnamed” Graph,btw the only one is the first I creat。And i try to use another visualizer which named Playable Graph Monitor,its sad I cant find the “Unnamed” Graph which was disappeared.Could you give me some ways to show other disappeared Graphs?
     
  30. sdf

    sdf

    Joined:
    Sep 6, 2012
    Posts:
    13
    How to get the Time in code?
    playable.GetTime() is different with which displayed in PlayableGraph Visualizer .