I'd use the findKeyframe call with the which flag to find first and last keyframes in the scene then work from that.
cmds.findKeyframe(which='last') Mark On 5 October 2012 06:57, Panupat Chongstitwattana <[email protected]>wrote: > In my current project we have very tight instruction not to have any > keyframes beyond the given timeframe at all. For example, if a shot lasts > from frame 1 to frame 100, any keyframe beyond that (-1, 0, 101 or even as > tiny as 100.1) cannot exist. > > I want to create a script that would tell the animator if they have any of > such keyframes. How should I approach this without having to loop through > all objects or loop through the entire timeline and beyond? > > Thanks. > > -- > view archives: http://groups.google.com/group/python_inside_maya > change your subscription settings: > http://groups.google.com/group/python_inside_maya/subscribe > -- ------------------------------------- Mark Jackson Technical Animation Director http://markj3d.blogspot.com/ -- view archives: http://groups.google.com/group/python_inside_maya change your subscription settings: http://groups.google.com/group/python_inside_maya/subscribe
