Animation interpolation

While doing prototype of my character class I’ve found that Panda doesn’t interpolate the actor’s animation. Futher investigation of ActorInterval sources and Character lib on the C++ side confirmed this conclusion - animations are played frame-by-frame without any interpolation in between. Am I right ?

That’s correct.

If you need more intra-frame detail, one option is to convert the animation at a higher sample rate, e.g. 60fps instead of 24fps.

David

Sorrily it will not help as I’m planning to scale the animation speed (down to very, very slow :slight_smile: )

Looked in the panda/src/chan and found that it’s not that hard to implement, what stops me is inability to compile CVS head in desired configuration (currently I have to specify --no-FMODEX --no-FFMPEG to makepanda) because of thirdparty dependency issues (see my post in “Compilation” forum).

any chance that you might be able to contribute your addition back to panda3d?

david, any chance to include this feature as an optional(!) feature (.setAnimationInterpolation)? this can be very useful for certain special effects.

thanks,
kaweh

You know, you’re right–this is pretty easy to implement. In fact, I just did implement it; it took a couple of hours.

With the current CVS version of Panda, you can enable this mode globally by putting:

interpolate-frames 1

in your Config.prc file, or on a per-Actor basis by calling:

actor.setBlend(frameBlend = True)

Sorry, I can’t help you with your build problems, however. I know nothing about FMOD or the change to FMOD-Ex, and I don’t maintain the thirdparty libraries. However, I think Josh may be preparing a new public release to go out soon; this release will presumably contain the relevant FMOD-Ex code. It disturbs me, though, that this is not compatible with the version of FMOD currently available–are you sure about that?

David

Thanks! Just checked it out from the CVS.

About the FMOD: for example, in panda/src/audiotraits/fmodAudioManager.h we see the line

virtual void setSpeakerSetup(SpeakerModeCategory cat);

and SpeakerModeCategory isn’t defined elsewhere. Reading the sources I could imagine that it should be ‘typedef’ to FMOD_SPEAKERMODE. There are some more errors like this but I’ll tell about them later as I’ve just started the build and it didn’t come to them yet.

Maybe some updates from your working copy haven’t make their way to CVS ?

Followup:

I’ve got things compiled with the current FMOD by patching panda/src/audio/audioManager.h and panda/src/audiotraits/fmodAudioManager.h (details are in in my post in “Compilation”). So maybe you should check if these files in CVS are really latest versions.