PDA

View Full Version : Problem in Smooth Repetition in Loops



ykarbaschi
12-04-2009, 02:31 AM
Hi to everyone,

I'm a beginner in XNA. I've watched the RealTime Shaders with XNA from Digital tutor and did everything completely. When I execute the program for debugging, everything seems Ok but there is a gap between each loop of the Animated character. I mean that it's not a seamless and smooth movement between repeated loops while I used the gcv.fbx from the CD. I don't know what is the problem. also I can't execute the exact code from the CD to compare with my code.

For your Kindest consideration:
Athlon 64 3800+
3Gb RAM
Geforce 7300 LE
Visual C# 2008
XNA Game Studio 3.1

Thanks

chrisg
12-04-2009, 01:37 PM
Hi ykarbaschi,

Try implementing this fix:


Here is a workaround. Paste this after you call your first animPlayer.update command. This will attempt to skip the first few frames of the animation clip upon looping back.



if (animPlayer.CurrentTime < TimeSpan.FromMilliseconds(32))
{
animPlayer.Update(gameTime.ElapsedGameTime, true, Matrix.Identity);
}

ykarbaschi
12-04-2009, 11:10 PM
Thanks a lot chrisg!

It worked well and it's because of wrong loop in .fbx file, isn't it?

Now I have another question. I am an intermediate user of MoBuilder. When I create my own loop for this character in another Take, everything go wrong. All body part go back to TPose Stance but have keys and move locally. In this situation, the "Take 001" don't work well anymore. I'm using Motion Builder 2010.

Thanks in advance for your time.

chrisg
12-08-2009, 09:28 AM
Hi ykarbaschi,

Can you attach a screenshot or project file that you're working with, so I can see better what's going on?

ykarbaschi
12-10-2009, 01:23 AM
Hi Chrisg,

Yes, This is a .fbx file which I edited with Motion Builder 2010. I made another Take, "Take 002" and created a simple loop for his hand. But I can't use this take at all. I can't use even "Take 001" no any more. It seems that, the file is completely corrupted.

I wanted to attach the .fbx file. But I couldn't. Also, I couldn't find your E-mail. What way do you suggest for getting my file?