University of Southern CaliforniaUSC
USC ICT TwitterUSC ICT FacebookUSC ICT YouTube

Animating SmartBody characters with AMC/ASF files | General SmartBody Discussion | Forum

Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Animating SmartBody characters with AMC/ASF files
June 15, 2015
11:06 pm
Avatar
Member
Members
Forum Posts: 21
Member Since:
July 16, 2014
sp_UserOfflineSmall Offline

Hi,

I am trying to get the motions from AMC files and apply that to the SB's skeleton.

motion = scene.getMotion(FileName)

I have the ASF file with the same name in the path. SB loads the ASF file but not the AMC file. I should also mention that, previously I had a problem with ASF as well. The ASF file exported by Blade, does not put the limits of the bones in the file, and I got an error for that. Therefore, I added this:

limits (-180.0 180.0)
(-180.0 180.0)
(-180.0 180.0)

to the end of each bone description in ASF files. But, still AMC is not loaded. Can you help me please?

June 15, 2015
11:15 pm
Avatar
Admin
Forum Posts: 980
Member Since:
December 1, 2011
sp_UserOfflineSmall Offline

The asf and the amc need to be in the same directory, and I would try to first name them with the same prefix, i.e. test.asf with test.amc.

Can you send me that pair so that I can see why they are not being loaded properly?

 

Ari

June 15, 2015
11:56 pm
Avatar
Member
Members
Forum Posts: 21
Member Since:
July 16, 2014
sp_UserOfflineSmall Offline

Ari,

Thanks for responding. Yeah, I have put them in the same directory and they have the same name. I just sent you my files.

June 16, 2015
9:04 am
Avatar
Admin
Forum Posts: 980
Member Since:
December 1, 2011
sp_UserOfflineSmall Offline

Ok, you need to first load the .asf file into SmartBody, then load the .amc file, and the .amc file needs to be named liked this:

ASFPREFIX_something.amc

in your case, your asf file is:

Contrast001.asf

so the .amc file needs to be named:

Contrast001_01.amc

or Contrast001_foo.amc, or Contrast001_bar.amc, or whatever.

and the amc parser will then look for a .asf file that has the prefix "Contrast001").

Now, you might have to retime the animation, since the .amc file comments say to use 120 fps (but .amc files don't have an explicit indicator for frame rate), and SmartBody will assume 30 fps, so you can do something like this once the files are loaded:

motion = scene.getMotion("Contrast001_01.amc")

motion.retime(4)

 

Ari

June 16, 2015
3:07 pm
Avatar
Member
Members
Forum Posts: 21
Member Since:
July 16, 2014
sp_UserOfflineSmall Offline

Thanks Ari,

I was able to load the motion on the skeleton. And, in order to do that I had to remove the extension (.amc) when loading the motion,

motion = scene.getMotion("Contrast001_01")

But, as you mentioned I have to fix the rate of the motion, it is 30 fps right now. But it gives an error when I use retime:

'SBMotion' object has no attribute 'retime'.

Do you know how I can fix that?

Many thanks

June 16, 2015
10:37 pm
Avatar
Admin
Forum Posts: 980
Member Since:
December 1, 2011
sp_UserOfflineSmall Offline

Try:

motion.downsample(4)

Forum Timezone: America/Los_Angeles

Most Users Ever Online: 733

Currently Online: mondayneedle1, juhlvalenzuela2, lanp4anase, worriedutopia9579, DixieDelgado, lyinglegacy8966, eric506784
85 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

jwwalker: 80

jyambao: 51

rbaral: 47

adiaz: 30

WargnierP: 29

lucky7456969: 28

mbarros: 28

avida.matt: 26

JonathanW: 24

laguerre: 23

Member Stats:

Guest Posters: 65

Members: 52460

Moderators: 3

Admins: 4

Forum Stats:

Groups: 1

Forums: 5

Topics: 427

Posts: 2343