XNA Creators Club Online
Page 2 of 2 (47 items) < Previous 1 2
Sort Posts: Previous Next

XNAnimation 0.7 BETA - Play nice animations on XNA!

Last post 1/24/2010 6:38 AM by somebb. 46 replies.
  • 8/6/2008 12:02 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    I've been looking at this for awhile, intending to use it eventually. I have some questions first.

    Does it run in 2008 and CTP 3.0?

    Do Fragmotion or trueSpace 7.6 .x files work well with this?

    Does it run well on slow cards? My 6100 bombs on anything that uses heavy shader work, and I'd like something I have planned to run on very low end machines.

    return;
  • 8/6/2008 11:05 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi,

    You can find the answer for most of your questions at the XNAnimation FAQ.

    Currently it does no support XNA CTP 3 but you could probably recompile it for the CTP 3 with minor changes. It will support the XNA 3 as soon as its reach its final release. 

    Any modeling tool should work fine as long as you it has a plugin for exporting to X or FBX that can export bones and animations.

    I was running it on a 6600 GT card and it worked fine. Not sure how it performs on a 6100, you should try one of its samples! =)

    Bruno Evangelista,
    Homepage | XNAnimation
    Ziggyware Article: Playing Nice Animations with XNA
    For what will it profit a man if he gains the whole world and forfeits his soul? Or what will a man give in exchange for his soul?, Matthew 16:26
  • 8/28/2008 9:12 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi Bruno

    I was looking for a quick way to test rigging as I'm learning the basics of modeling and animation with truespace, milkshape, and blender. A lot of time can be spent learning these tools especially when trying to find out which animation library is a good fit.

    I created a gingerbread man model in a blender animation demo with KiloWatt in XNA. KiloWatt doesn't actually play the animations I had created in the Action editor. The model does render in XNA at least. No errors reported. I can even see the names of my Animation Clips in the VS express when running the debugger. Note: I had made a complete skeleton btw.

    I tried using XNAnimation to load the same model following your example Playing Nice Animations on XNA but my model only has some basic shading to get around some material loading issues. I get errors that say my model isn't skinned. Does it need to be fully textured ? Can you post any pointers for getting a minimalist set up for those of us just starting out?

    BTW I really like that you include all of the source (step by step) to get a basic demo going. Thanks for that.

    Tomo 

  • 8/28/2008 11:18 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi Tomo,

    XNAnimation only supports skinned models and skinned animations. You will not be able to play ordinary animations like translations and rotations on it, unless you create a bone for it... =(

     

    Bruno Evangelista,
    Homepage | XNAnimation
    Ziggyware Article: Playing Nice Animations with XNA
    For what will it profit a man if he gains the whole world and forfeits his soul? Or what will a man give in exchange for his soul?, Matthew 16:26
  • 8/28/2008 11:38 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    You can download the KiloWatt Animation Library. It comes with an animation viewer tool, which allows you to just add the meshes to the content project, and then browse/select and animate them at runtime. It works with both skinned and non-skinned animations (and combination skinned and non-skinned).
    Jon Watte, Direct3D MVP
    Tweets, occasionally
    kW X-port 3ds Max .X exporter
    kW Animation source code
  • 8/28/2008 11:45 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Like this ?  I don't get the skinned errors any more, after loading model in XNA. But...

    yo

    I only see a blue screen now. I tried increasing the scale of the model, but it's still not showing up in XNA...

  • 8/29/2008 12:11 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Before you skin a model you need to freeze it, or reset xform. And you can also try reducing its size with scale.
    Bruno Evangelista,
    Homepage | XNAnimation
    Ziggyware Article: Playing Nice Animations with XNA
    For what will it profit a man if he gains the whole world and forfeits his soul? Or what will a man give in exchange for his soul?, Matthew 16:26
  • 8/29/2008 1:48 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    I'm not sure what you mean by reset xform or freeze it. I got him to animate! From the starting position he's supose to wave his arm straight up and down like in a jumping jack position.

    But for some reason his arm is bent in front of him like he's turning a screwdriver... Something is going wrong.

    he's waving
  • 9/2/2008 2:57 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Has anyone been able to work out how to obtain the world position of a bone using this animation system? Bruno is pretty busy and isn't able to be around on the official forums.

     http://www.codeplex.com/xnanimation/Thread/View.aspx?ThreadId=34626 details what we've tried.

    Bino
    aka Borealis
  • 9/21/2008 2:41 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi, Bruno

    I have already bought your book (Beginning XNA 2.0 Programming From Novice to Professional).

    Your book is very usefull.

    I want to ask something about you XNAnimation 0.7.

    What can I render the model as cell shade?

    I try to change effect properties but it doesn't look like cell shade.

    Help me plzz.

    Thank in advance.

  • 9/21/2008 8:44 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    You can do that creating a shader that post-process the final image of the scene. There's an example of a cartoon render shader on my homepage (www.brunoevangelista.com). You will need to also change the lighting in the skinned model shader, setting a fixed number o tons (2 or 3) like in cartoon drawing.

     


    Bruno Evangelista,
    Homepage | XNAnimation
    Ziggyware Article: Playing Nice Animations with XNA
    For what will it profit a man if he gains the whole world and forfeits his soul? Or what will a man give in exchange for his soul?, Matthew 16:26
  • 9/22/2008 3:04 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Bruno Evangelista:
    You can do that creating a shader that post-process the final image of the scene. There's an example of a cartoon render shader on my homepage (www.brunoevangelista.com). You will need to also change the lighting in the skinned model shader, setting a fixed number o tons (2 or 3) like in cartoon drawing.

    Thanks for your answer.

    I have already apply post process the border like cartoon.

    But I have no idea to make it look like the flat shade or toon shade.

    I really want to use your XNAnimation 0.7 BETA library.

    I can render as toon shade with SkinnedModelSample because this sample has the effect file (SkinnedModel.fx).

    But your library does not have effect file (.fx) to change to toon shade.

    I have no enough ability to change effect from your skinnedModelBasicEffect to be toon shade.

     

    I have another question.

    Now, I do the project about dodge ball game.

    In maya, I make join for ball position on hand.

    I want to put the ball to the player's hand.

    If I want to reach the joint with your XNAnimation library, what can I do?

    plz help me again......

     

    ps. If you can give me some example code, it is best thing for me.

    Thanks in advance.

  • 9/22/2008 4:29 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi, A lot of people have been asking for sample on how to attach an item to the hand of a player and I'm unable to provide a sample for it right now! But this thread might help you: http://www.codeplex.com/xnanimation/Thread/View.aspx?ThreadId=34626
    Bruno Evangelista,
    Homepage | XNAnimation
    Ziggyware Article: Playing Nice Animations with XNA
    For what will it profit a man if he gains the whole world and forfeits his soul? Or what will a man give in exchange for his soul?, Matthew 16:26
  • 9/25/2008 7:41 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi, Bruno

    I try to do  follow your suggestion.

    It does not work at all.

    I can get the world of hand's joint by

    int i = skinnedModel.Model.Bones["HandJoint"].Index;

    Matrix handWorld = animationController.SkeletonBoneTransforms[i];

    And I update the ball's position by

    ballController.update(gameTime.ElapsedGameTime, handWorld);

    Result is :

     

     

    It seems the ball position is on the foot joint.

    I do not know how can I do solve this problem.

    plz plz plz

     

    Thanks in advance.

  • 11/25/2008 7:33 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Hi Bruno


    Just wondering, how do you remove the bind pose from our animations?

    My artist is exporting our model and animation, and for some reason, it includes the bind pose (static frame) on the end of the animation, and it effects the blending. Why is this happening and how do we remove it so that it plays nice like your examples? Cheers
  • 11/26/2008 12:53 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi;}

    I tracked it down to not being the bind pose issue. It is actually to do with the duration of the animationclip.

    Whenever we export the animations from Max using KWXport, it has issues with the duration of the animation. It seems that the animations will play, but then pause and wait out for a set duration. In this case, it waits for duration of 00:00:01. No matter what the animation.

     

    I felt that this was due to the stretch variable in the KWXporter. Is everyone using a different exporter? And if so which one. Otherwise how do we counterpart this issue. Thanks.

  • 11/27/2008 10:54 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Jon Watte will probably be able to answer your question more accurately than I, but, as far as I'm aware the issue lies with the actual .x format itself. I vaguely remember reading somewhere at some point in the past; that, animations with a length of less than a second are automatically padded, and become one second long (Additionally, I seem to remember getting an "E_FAIL" error when attempting to import a .x model with more than two animations declared in the KW-X Port UI into XNA using the default content importer). In my opinion KW-X beats Panda's exporter, and even Autodesk's .fbx exporter in terms of reliability, so I would say you should stick with it.

    The XNAnimation library provides an animation splitting functionality by way of .xml. To use it all you need to do is export all the animations for your model as a single 'take' and then construct an .xml file with the same hierarchy as the .xml provided in the XNAnimation sample project, "EnemyBeastAnimations.xml" is its name I believe. For each animation, you specify a name, starttime/startframe and endtime/endframe, and then you can access it with SkinnedModel.AnimationClips[name] or SkinnedModel.AnimationClips.Values[index].
    Lost C1tY
  • 11/28/2008 12:08 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Ahh that is definitely the issue. Thank you.

    I did track it down to what I thought was a padding issue, but wasn't 100% sure because I couldn't use any other exporter to work with the assets I was using.
    I did find a work around, but for what I need to end up using, this will not be a problem. Thank you very much for your information, it will help alot.
  • 11/28/2008 3:05 PM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Not a problem mate. I've used the library a fair bit, so if you run into any more issues, just ask.
    Lost C1tY
  • 12/16/2008 7:02 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Sorry just one last question. You might save me tracking it down.

    I have set the animation to not loop, and not lerp at all, and on the last keyframe that it should hold, it seems to be going back to the first keyframe. The time in the animation controller still says its the duration, 46.967 seconds. So is this a content pipeline issue, a animation controller issue, or an model exported issue?

    Thanks, I have been playing around with this system and re-writting the shader to make it better, but I thought you might be able to save me time in tracking this down if you have come across it yourself already. Cheers.
  • 12/17/2008 1:01 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    Sorry found it. There is a bug in the AnimationControllers' update routine. The controller would lerp between the last and first frame when the animation isn't looped and finishes playing. This is completely wrong. Anyway, is all good and fixed now :) Cheers
  • 1/24/2010 6:38 AM In reply to

    Re: XNAnimation 0.7 BETA - Play nice animations on XNA!

    hi Adam,

    I would like to know how to fix this problem? Is below there? I just comment the If function that it is can solved the problem. Thank!

    (AnimationController.sc)

           /// <inheritdoc />
            public void Update(TimeSpan elapsedTime, Matrix parent)
            {
                //if (hasFinished)
                   // return;

                // Scale the elapsed time
                TimeSpan scaledElapsedTime = TimeSpan.FromTicks((long) (elapsedTime.Ticks * speed));

                if (animationClip != null)
                {
                    UpdateAnimationTime(scaledElapsedTime);
                    if (crossFadeEnabled)
                        UpdateCrossFadeTime(scaledElapsedTime);

                    UpdateChannelPoses();
                }

                UpdateAbsoluteBoneTransforms(ref parent);
            }
Page 2 of 2 (47 items) < Previous 1 2 Previous Next
var gDomain='m.webtrends.com'; var gDcsId='dcschd84w10000w4lw9hcqmsz_8n3x'; var gTrackEvents=1; var gFpc='WT_FPC'; /*<\/scr"+"ipt>");} /*]]>*/
DCSIMG