AREA forums upgrade
Read more about the planned upgrade of our forums
  • 1/3
You are here: Forum Home / Autodesk® MotionBuilder® / Python / Animation Clip.Offset and MarkOut
IMPORTANT ANNOUNCEMENT ABOUT AREA FORUMS
  RSS 2.0 ATOM  

Animation Clip.Offset and MarkOut
Rate this thread
 
64704
 
Permlink of this thread  
avatar
  • thieljoe
  • Posted: 23 February 2012 08:27 AM
  • Total Posts: 2
  • Joined: 01 August 2009 05:40 PM

greetings,

Currently attempting Creating Animation Clips in the Story, that have Offset Start Times (FirstLoop) , whenever this value is set then the clip loops every frame appearing black in the Animation Track. If i manually set the MarkOut value to a large number then it is fixed (not looping), but setting this value through python does not affect the clip. additionally many of the other values do not seem to be affected when set in the script, (FirstLoop , LastLoop, Loop, AutoLoop etc.). the MarkOut keeps getting set to 1 frame when Offset.

is there an alternate way to set this MarkOut value, or is the way im currently setting the Offset incorrect? i’ve tried changing the order of setting the values but no luck.

here is example code , with attemptings to set the Offset / MarkOut:

from pyfbsdk import *
try:
    
lTrack FBStoryTrack(FBStoryTrackType.kFBStoryTrackAnimation)
    
lTrack.Label "Animation Track"
    
lAnim "C:\example.fbx"
    
lClip FBStoryClip (lAnimlTrackFBTime(0,0,1,0)) 
    
    
lClip.Loop 0
    lClip
.AutoLoop 0
    lClip
.OffsetEnable 1
    
    lClip
.Start FBTime(0,0,1,5)
    
lClip.Offset FBTime(0,0,3,0)
    
lClip.Stop FBTime(0,0,6,1)
    
    
lClip.FirstLoop FBTime(0,0,0,15)
    
lClip.LastLoop FBTime(0,0,20,1)
    
    
lClip.MarkOut FBTime(1,20,20,1)

except IOError:
    
FBMessageBox"Cannot Continue""Unable to read the audio track definition file you selected or you have not selected one.""OK"NoneNone )
    exit


Replies: 0
avatar
  • Ollie_D
  • Posted: 24 February 2012 11:01 PM

What version are you using?  This is a bug in 2011 that is fixed in 2012.  Unfortunately there was no work around I could find, other than upgrading.  It just had to adjusted manually once the clip had been loaded.  Even then it would often cause this error.



Replies: 0
avatar
  • thieljoe
  • Posted: 26 February 2012 01:57 PM

ah thank you for this confirmation , we are indeed using 2011 ,
ill continue to fix manually after the running script.



Replies: 0