Attribute update during timeline scrub?

86 views
Skip to first unread message

Kenneth Ibrahim

unread,
Jul 8, 2014, 2:47:35 PM7/8/14
to python_in...@googlegroups.com
Hi,

I'm trying to get a heads up display to update based on an object attribute's animated value while scrubbing in the Timeline. This doesn't seem to work and only updates upon release of the mouse button. It seems that values in the AE & ChannelBox also don't update until releasing the mouse.

Does anyone have any idea if this is possible? The PolyCount HUD does seem to update while scrubbing for instance...

Thx! Ken

--
"God is a metaphor for a mystery that absolutely transcends all human categories of thought. It's as simple as that!" - Joseph Campbell

Mark Jackson

unread,
Jul 8, 2014, 3:04:45 PM7/8/14
to python_inside_maya
You need to attatch it to the timechanged event in the Headsup display call:

                    cmds.headsUpDisplay(metaHudItem,
                                        section=section,
                                        block=block,
                                        blockSize=self.size,
                                        label=attr,
                                        labelFontSize=self.size,
                                        allowOverlap=True,
                                        command=partial(getattr,self,attr),
                                        event='timeChanged')

I've done a nice neat wrap of all of this in the Red9 StudioPack, you can select the attrs you want to monitor in the ChannelBox, RMB>Red9HUD>addMonitored attr:


Be worth a look, if not just to poke into the code

cheers

Mark


--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/CAP_aC5bB9AphX9L23Ay9Rx9ZczkydL0kiXwbB7CaY_gVW_Kcww%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.



--
-------------------------------------
Mark Jackson
Technical Animation Director
http://markj3d.blogspot.com/

Kenneth Ibrahim

unread,
Jul 8, 2014, 3:12:27 PM7/8/14
to python_in...@googlegroups.com
Thanks for the feedback. I've already defined that event ('timeChanged') to no avail which is why I'm reaching out. Somehow I thought that would be it.

Is there perhaps a setting in Maya to have all attributes evaluated and updated while scrubbing that would then update the HUD as a by-product?

Thx! Ken



For more options, visit https://groups.google.com/d/optout.



--

Kenneth Ibrahim

unread,
Jul 9, 2014, 4:54:20 PM7/9/14
to python_in...@googlegroups.com
Nice looking tool and video intro. Having seen that I was able to get this working by switching from using the 'timeChanged' event to simply specifying the 'attachToRefresh' option :)

Mark Jackson

unread,
Jul 10, 2014, 5:33:30 AM7/10/14
to python_inside_maya
yeah it's been a god's send whilst setting up facial systems, just selecting the channels and throwing them up onto the HUD for debug.

cheers

Mark



For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages