def dragLeft(self):
'''This is activated by the left mouse button, and weights to the next or previous keys.'''
#clamp it
if self.x < -1:
self.x = -1
if self.x > 1:
self.x = 1
if self.x > 0:
self.drawString('>> '+str(int(self.x*100))+' %')
for curve in self.keySel.curves:
for i,v,n in zip(self.time[curve],self.value[curve],self.next[curve]):
mc.keyframe(curve, time=(i,), valueChange=v+((n-v)*self.x))
elif self.x <0:
self.drawString('<< '+str(int(self.x*-100))+' %')
for curve in self.keySel.curves:
for i,v,p in zip(self.time[curve],self.value[curve],self.prev[curve]):
mc.keyframe(curve, time=(i,), valueChange=v+((p-v)*(-1*self.x)))
评论列表
文章目录