[Closed] Help me with simple motion mixer control and render seting ♥
Hello there, I am creating a sprite sheet/ animation frames from the character with many animations that I added to the Motion mixer tool. For each Motion Clip, I need to modify manually the parameter such as turning on the Solo button on each Motion Clip, changing the frame range to render, creating folders to save render frames. It’s a pain to work with thousand of animation frames.
I have read the Max script Help for control motion clip mixer but it is confusing for me to understand. Unfortunately, the Macro Recorder does not read these operations on the Motion Mixer tool or Render Setting, and the sample scripts are very few on the internet making me hard to learn
Hope you guys can give me some light, please.
All I need the script to do is:
For each MotionClip do
(
Turn on Solo mode of active MotionClip
Get the name of active MotionClip
Get the length of active MotionClip
Set render frame range with the length of active MotionClip
Create a folder with the name of active Motion Clip and save the render output path
Run render
Wait until the render progress is done
Next MotionClip
)
Thank you very much!!
I have found some code samples very useful for this problem, in the post 10 years ago from other 4rum. Here it is for those who need it Have fun!
–ITERATE THROUGH MIXERS
for m = 1 to theMixer.numMaxMixers() do
(
currentMixer = themixer.getMaxMixer m
--ITERATE THROUGH TRACKGROUPS
for t = 1 to currentMixer.numTrackgroups do
(
tg = getTrackgroup currentMixer t
trackCount = tg.numTracks
--ITERATE THROUGH TRACKS
for tC = 1 to trackCount do
(
currentTrack = getTrack tg tc
--ITERATE THROUGH CLIPS
for c = 1 to currentTrack.numClips do
(
currentClip = getClip currentTrack c
format "Name: %\n" currentClip.filename
format "\tStart: %\n" currentClip.globstart
format "\tEnd: %\n" currentClip.globend
)
)
)
)