Blending different animations

Discuss programming topics for the various GPL'd game engine sources.
Post Reply
JasonX
Posts: 422
Joined: Tue Apr 21, 2009 2:08 pm

Blending different animations

Post by JasonX »

Even though the way Q3 handles animation blending is elegant, it requires a much more complex art pipeline, forcing artists to think in separate body parts. I'm thinking about starting a simple test in QuakeSpasm and implement animation blending in multiplayer: running and shooting, for example, without sliding. More complex stuff would follow, but this is a good way to start and learn more about animations. Has anyone tried this before in Quake? Is it possible only with CSQC? Who handles the animations, the engine or QuakeC?
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: Blending different animations

Post by Baker »

You know Quakespasm doesn't support MD3 right?

Quakespasm is stock Quake:
1) .mdl, .spr, .bsp
2) standard QuakeC
3) no view weapon support of any kind
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
JasonX
Posts: 422
Joined: Tue Apr 21, 2009 2:08 pm

Re: Blending different animations

Post by JasonX »

I'm implementing IQM and skeletal animation support. Somewhat works... but now i want to experiment with blending, otherwise, IQM would be useless.
Baker
Posts: 3666
Joined: Tue Mar 14, 2006 5:15 am

Re: Blending different animations

Post by Baker »

JasonX wrote:I'm implementing IQM and skeletal animation support. Somewhat works... but now i want to experiment with blending, otherwise, IQM would be useless.
I hear you.
The night is young. How else can I annoy the world before sunsrise? 8) Inquisitive minds want to know ! And if they don't -- well like that ever has stopped me before ..
Spike
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK
Contact:

Re: Blending different animations

Post by Spike »

JasonX wrote:Even though the way Q3 handles animation blending is elegant, it requires a much more complex art pipeline, forcing artists to think in separate body parts. I'm thinking about starting a simple test in QuakeSpasm and implement animation blending in multiplayer: running and shooting, for example, without sliding. More complex stuff would follow, but this is a good way to start and learn more about animations. Has anyone tried this before in Quake? Is it possible only with CSQC? Who handles the animations, the engine or QuakeC?
there was a q1md3 mod a while back which supports 3-model md3 players via ssqc tag extensions.
my old csqctest mod has support for csqc-driven ppm md3 player models (it parses animiation info and everything), but is now pretty much uninteresting otherwise.

regarding who handles the animations... 'yes' is as good an answer as any.
csqc has frame, frame2, lerpfrac, frame1time, frame2time, and can thus select animations+time into animations+lerping, for 4-way lerps.
ssqc has only frame, and the client decides the frame2+lerpfrac+frame1time+frame2time as it feels is most appropriate.

In fte's csqc, there is also some basebone+baseframe+baseframe2+baselerpfrac etc fields to control the 'base' bones of the model. thus set basebone to the hips and then baseframe controls bone indexes below while regular frame controls above.
I never did make an ssqc extension to network basebone+baseframe from ssqc (yay network protocol changes!), but if you're an engine coder, doing so is the easiest way to separate torso+legs with an iqm model without depending upon csqc and its skeletal objects extension.
the problem with this is that it merely separate torso+legs. only being able to select a single animation will not give you anything close to foot-sync, and will look weird when changing directions, which is kinda why I never bothered.


iqm has a much smaller memory footprint/file size than the equivelent mdl model, at least with high frame counts. it is still useful even without weird animation stuff, if only because of its higher vertex precision.
JasonX
Posts: 422
Joined: Tue Apr 21, 2009 2:08 pm

Re: Blending different animations

Post by JasonX »

You're a living encyclopaedia, Spike. Thanks!
mankrip
Posts: 924
Joined: Fri Jul 04, 2008 3:02 am

Re: Blending different animations

Post by mankrip »

JasonX wrote:You're a living encyclopaedia, Spike. Thanks!
:D I second that.
Ph'nglui mglw'nafh mankrip Hell's end wgah'nagl fhtagn.
==-=-=-=-=-=-=-=-=-=-==
Dev blog / Twitter / YouTube
Post Reply