Exporting pose from Blender

Post » Sat Feb 19, 2011 6:50 am

Well, I'm trying to learn to animate/create poses.
Doing the dirty work in Blender is fine, I can move bones and stuff follows, but when I try to look at my creation ingame, the pose seems corrupt. (the character looks like he's in a black hole, everything is smudged all around)

So I read something about Vert. Groups, and this is where I think the problem is, because when I try to add this to the skel+stuff everything moves away from the bones. I don't know enough about this to make that seem logical and so I'm totally lost!

I've uploaded the pose on 4Shared http://www.4shared.com/file/Fy8jxOA9/GrayfoxAnim.html

Hope someone can help / explain to me why this happens.

PS: I know it might be hard to understand how the anim appears ingame, but it's hard to tell, but I think you've seen corrupt havok (NPC's slung around the place, only in this case in one place)

Kevin
User avatar
Dona BlackHeart
 
Posts: 3405
Joined: Fri Dec 22, 2006 4:05 pm

Post » Sat Feb 19, 2011 1:35 am

Well, I'm trying to learn to animate/create poses.
Doing the dirty work in Blender is fine, I can move bones and stuff follows, but when I try to look at my creation ingame, the pose seems corrupt. (the character looks like he's in a black hole, everything is smudged all around)

So I read something about Vert. Groups, and this is where I think the problem is, because when I try to add this to the skel+stuff everything moves away from the bones. I don't know enough about this to make that seem logical and so I'm totally lost!

I've uploaded the pose on 4Shared http://www.4shared.com/file/Fy8jxOA9/GrayfoxAnim.html

Hope someone can help / explain to me why this happens.

PS: I know it might be hard to understand how the anim appears ingame, but it's hard to tell, but I think you've seen corrupt havok (NPC's slung around the place, only in this case in one place)

Kevin


Hi Kewin,

I looked at your Blender scene, and saw some things wrong with how you were making the animation.

Firstly, here are my Blender scenes, based off of your org. one (and my exported nifs/kfs related to it):

http://www.gamefront.com/files/20260394/GrayfoxAnim_KPTweaks.7z

I am not sure, but are you trying to make a statue pose?

There are two ways to make a stationary pose, good to make characters look like statues.

The easiest way, for a pure statue character ingame (in other words, will not need to animate any other way at all), is to go to timeframe of 1 in Blender for your pose, select the armature, go into "Edit Mode", then go to "Pose" button/tab, then select "Apply Pose as Rest Pose". Then go back to "Object Mode", and CTRL+A -> Scale & Rotation to ObData, and then go back and do "Visual Transforms to Objects Loc/Scale/Rot" (might sure if needed, but I did this one too, just in case). Then import the body mesh parts of the race you want to make the pose of and parent them to the armature. Select all the meshs parts, and go to "Objects" -> "Scripts" - "Apply Deformation". Then delete the skeleton, select all the body/armor meshes, and export them as "Geometry Only". This way, you don't need to apply any exported animation to an animated character. For a statue, this also saves on the nif's filesize, to help performance. I think it was "Da Mage" who authored this info originally, for statues.

The second method, needs an animation. You forgot to put "start" and "end" markers in your animation's timeline. Select the armature, and go into "Pose Mode". Go to timeframe of 1, and go to "Frame" -> "Add Marker"...then go back and go to "Frame" -> "Name Marker"...a small text window will pop up...type the info as follows: start -name SpecialIdle . Then go to the ending timeframe of the pose, and do the same thing, except type : end . I saw you had entered a keyframe pose for the bones at timeframe of 1 (represented by that vertical blue line in the "Timeline" window), but you need to add another one at the ending timeframe. So slide the Timeline bar to be over timeframe of 2 (your ending timeframe), click the red circle icon so that it selects "Add/Replace Keys"..then click the yellow key icon - this will insert a second blue line there). Then, export the animation. You can then either import the animation directly into the nif, to make another type of statue pose...or apply the pose to living/breathing/moving actors using the CS "Idle Manager" along with proper scripting variables and such , when you want them to strike the pose.


Animation Export Settings that I used: http://img638.imageshack.us/i/screenshot2en.jpg/

Be sure you don't use the skeleton in yours or mine Blender scene, in the game. It lacks collision/constraints upon export, and if a race dies that uses it, bad things will happen in game (if you don't CTD first). Use the original Drake skeleton, that has collision and constraints within its nif, as can be checked in Nifskope.

I have not checked my exported files in the game, for said above reason.

Koniption
User avatar
katie TWAVA
 
Posts: 3452
Joined: Tue Jul 04, 2006 3:32 am

Post » Sat Feb 19, 2011 6:35 am

It may be this simple:

what the last thing you imported the player skeleton? if not (aka, you imported the skeleton first, then some meshes like body parts) just import the player skeleton again, once imported, delete the skeleton you just imported, now xport your pose again.

I ran into this problem when i first started, seems re-importing fixes some hidden settings that get changed when another mesh is imported. This is just a common problem though, it may not be yours....animations are very tricky things to learn.
User avatar
Tiffany Castillo
 
Posts: 3429
Joined: Mon Oct 22, 2007 7:09 am

Post » Sat Feb 19, 2011 10:55 am

The pose was created for the player, not a statue, I really appreciate your answer, it's very detailed!
Basicly it seems that I didn't lock the pose in it's place? And that I have to put that start/end things in, I've writen your reply down :thumbsup:

However, I tryed the pose ingame (the one you exported) and I seem to get the same result, maybe I'm doing something else wrong?
I replaced the pose with another pose in one of Gomas mods. Is there something special with these mods perhaps?

I noticed Goma has "SpecialIdle_CastSelf" instead of your "SpecialIdle_GrayFoxPose", isn't it enough to just rename the prefix, or might this be the source?

Thank you again, learning alot here!
User avatar
Jessica Nash
 
Posts: 3424
Joined: Tue Dec 19, 2006 10:18 pm

Post » Sat Feb 19, 2011 11:57 am

Yep, tried out your animation, was just I had suspected.

Import your orginal skeleton (no animation) into blender again, once imported, delete that skeleton you just imported. Then export your skeleton that has the animation on it. Ta-da! it will now work.


There is one problem, it has the location/rotation issue with it, so when played they sink half into the ground and are aa a 90 degree turn. I can't remember how to fix that (its another common bug) Koniption might be able ot help there.
User avatar
Cheville Thompson
 
Posts: 3404
Joined: Sun Mar 25, 2007 2:33 pm

Post » Fri Feb 18, 2011 10:45 pm

There! You're right, sorry for not trying that, but it felt far fetched that just import/delete a new skeleton would change anything, he he :sweat:

There is also, together with the problem you said da mage, a problem with the head not being positioned like the Blender image.
User avatar
ONLY ME!!!!
 
Posts: 3479
Joined: Tue Aug 28, 2007 12:16 pm

Post » Sat Feb 19, 2011 2:04 am

There! You're right, sorry for not trying that, but it felt far fetched that just import/delete a new skeleton would change anything, he he :sweat:

There is also, together with the problem you said da mage, a problem with the head not being positioned like the Blender image.


EDIT: I just compared your skeleton to the vanilla skeletonbeast.nif, using Nifskope. I compared the skeletons, as they exist, in "rest pose'" (base, unanimated pose) - which is how the skeleton should be exported for use in creatures and player races. Virtually all of your skeleton's bones, have different Translation and Rotation values than their respective counterparts of same name, in the skeletonbeast.nif. So the skeleton in the Blender scene seems very "dirty", I guess is the best way to put it. What you need, is to work with a skeleton, whose "vanilla"-based bones have same Translation and Rotation data as the vanilla skeletonbeast.nif. It's ok for your "winged" skeleton to have extra bones, like for wings, and such...but any bones in the winged skeleton, that also exist in the vanilla skeleton, need to have the same Translation and Rotation data in Block Details, in Nifskope. Do you have the original "winged" skeleton you are using, BEFORE it is imported into Blender to be animated? If so, open it up in Nifskope, and then open up the vanilla skeletonbeast.nif in a second Nifskope window. If you go to "Block Details" for each bone of same name, between the two windows for the different skeletons, and see if the Translation and Rotation data is different between the two skeletons for those bones. If so, then you have a bad skeleton to begin with, and need to find an undirty one. Once you find a "clean" skeleton, import it into Blender, and redo your pose, then re-export your animation.

------------------------------------------------------------------------------
Previously written stuff below, but see above paragraph first!

I hope I make sense today; I feel a little under the weather:

For your "Winged" skeleton that you are using, you need to make sure the Bip01, Bip01 NonAccum, and Bip01 Pelvis nodes/bones, have their "Translation, Rotation, and Scale" data match the ones of same name in the vanilla "skeleton.nif". I don't know how to fix this issue in Blender, and I just spent the last couple of hours trying to figure it out... so I suggest using Nifskope to manually change the data of those two bones.

Next, import that newly NifSkoped skeleton, delete the original skeleton in the Blender scene, and rename the newly imported skeleton, to "Scene Root" (and not "Scene Root.00", or whatever other name it imports as). You might have to rename it under in the fields under that "square" icon, and the "three arrow" icon fields.

Then try reexporting your animation using the newly imported skeleton. See if it plays fine in the CS and in the game.

Also, something to note is this: http://niftools.sourceforge.net/forum/viewtopic.php?f=24&t=2438

Specifically, in regards to animation kfs : "Actually the X and Y positional -> but not rotational -> data needs to be on the Bip01 node and the Bip01 NonAccum needs to have the Z positional and all rotational data." -SaidenStorm

As for the helmet issue, try deleting the Armature "modifier" on the helmet. Do CTRL+A on the helmet to "Apply Scale & Rotation". Then repose the helmet to proper pose. Then re-add that Armature modifier, and name that modifier to "Ob: Scene Root" and unclick "Envelopes" on it (I think).

Koniption
User avatar
Steve Fallon
 
Posts: 3503
Joined: Thu Aug 23, 2007 12:29 am

Post » Sat Feb 19, 2011 10:56 am

Let's see... I've tried to use the vanilla TES skeleton instead, and created the pose again. I got the pose ingame on the first try this time (thanks to all the new help), but the pose is still down in the ground (don't really care about that, I can jump and toggle collision).

My main problem is the head however, the head is the only part that doesn't follow the pose... Or maybe it does, but not the way blender tells me the bone is rotated. It's really frustrating how the pose seem to work, all exept one freaking bone :facepalm:
User avatar
Melanie Steinberg
 
Posts: 3365
Joined: Fri Apr 20, 2007 11:25 pm

Post » Sat Feb 19, 2011 6:06 am

The only thing I can think over is the fact that the engine overwrites the head bone animation (so it rotates to look at nearby actors).......how are you testing it?, if there arent any nearby actors then the head should go to the pose poistion.
User avatar
Syaza Ramali
 
Posts: 3466
Joined: Wed Jan 24, 2007 10:46 am

Post » Sat Feb 19, 2011 9:58 am

It's a matter of bone priorities in the animation I think. The hardcoded head-tracking will always override animations unless the bone priorities of the animated bones are high enough to prevent this. I don't remember anymore which specific values it was, there was a webpage I was always looking up some reference values from, but I know I got idle animations that don't care about the game's head-tracking and it doesn't happen while they play.

As for the skeleton, I don't know what happened there. I created this skeleton by copy- & pasting only my new custom bones into the Vanilla one, all existing bones remained untouched. I haven't yet succeeded in getting anything usable out of Blender or NifSkope in regards to fully custom PC/NPC skeletons created from scratch, so this is the only way I'm doing it currently. All things Vanilla remain Vanilla.
User avatar
Sheila Esmailka
 
Posts: 3404
Joined: Wed Aug 22, 2007 2:31 am

Post » Sat Feb 19, 2011 3:15 am

There doesn't seem to be any problem with the skeleton Drake, the same outcome comes with the vanilla skel.

I found this, I'll try to look into it, http://www.truancyfactory.com/tutorials/animation_bonePriorities.html.

Edit: Tried to change the priority of the bone, doesn't seem to do the trick.
http://www.4shared.com/file/F1dhdZxO/Blender_Help.html if someone want to have a lookzie, I'm totally mindblown when it comes to these things (irregularities in something that seem constant)
User avatar
Naomi Lastname
 
Posts: 3390
Joined: Mon Sep 25, 2006 9:21 am

Post » Sat Feb 19, 2011 8:21 am

HI Kewin,

I downloaded your new uploaded file. I'll try to take a look at it when I can. It might be 3 to 4 days, though, due to my RL schedule. Or it might be today - I just don't know yet. I hope you can wait that long (up to 3-4 days)?

While I'm at it, please tell me what versions of the following programs you are using:

Blender
Blender NifScripts
Python
PYFFI

Koniption
User avatar
The Time Car
 
Posts: 3435
Joined: Sat Oct 27, 2007 7:13 pm

Post » Sat Feb 19, 2011 6:00 am

I did manage to get time to look at your new files you uploaded.

Firstly, here are my tweaked versions of your files:

http://www.gamefront.com/files/20269277/Blender+Help+KP.7z

It seems you are using the "First Person" skeleton to make your pose - this is causing issues. It causes issues, because the 1st Person skeleton in the "_1stPerson" folder, has the "Camera" bone in it. When I tested my fixes to your Blender scene, using the exported Idle of mine..when I talked to the "pose animation test subject" in the game, he played the gray fox pose (without sinking into the ground, thankfully), but then the camera started to continually jump up and down. I tried to force the Idle without talking to him, but I think I did the scenario in the CS wrong.

You need to make your pose, using the 3rd person skeleton located in the "_male" folder.

Also, it seems your pose is exporting with the shoulder & wrist "helper" bones, and are referenced and animated in the animation. I don't know if this will cause issues, but I looked at vanilla animations for the playable races, and their animations do not export with those bones referenced. It might be an issue; or might not be.

As for why the animation played without sinking into the ground (which hopefully also happens if you get the forced idle scenario correct on your end): you forgot to do the following in Blender -

You forgot to put in a keyframe, FOR ALL BONES, at beginning and end of the pose animation. You only had one or two bones that had a keyframe at beginning and end of the animation. If you look at my Blender scene, that I renamed and sent back to you in the above upload, look to the far left window. It's the window selection that is called the "Action Editor", and is represented by an icon that looks like a human stick figure. This is a handy window when it comes to animating. What it shows you, are all the keyframes for all bones in an up-to-down listing. The "Timeline" window only shows you the keyframes for each bones as you click on them individually in "Pose Mode". So get used to loving the "Action Editor" window - it's quite handy. It also showed me what was wrong. What I saw, in the bone listing in that window, was that all bones had a "diamond" icon at the ending timeframe, but vast majority had no "diamond" icon at the starting timeframe. This is the reason your animation exported without the "NiTransformData"s for each "NiTransformInterpolator", if looked at in Nifskope. NiTransformData must export under its respective NiTransformInterpolator, for each bones, that is animated...otherwise, your animation won't work as intended.

To get all bones keyframed easily at beginning and end, go to Pose Mode, CTRL+A to select all bones, then go to the Timeline window, make that red dot say "Add/Replace Keyframes", and at beginning and ending timeframes, click the "yellow key icon" once. In that "Action Editor" window, you will see that you have diamond icons for the beginning and ending timeframes, for each bone.

Lastly, I got around to thinking, about how you're handling that helmet in Blender...are you wanting the helmet to visually animate and come off the head, in real time when your pose is called?

If not, cool. If so, you are doing it wrong. You might have to opt for either making an "offsetted" or "nonrestrained" bone that is extruded from the 3rd person skeleton head bone. By offset, I mean that the bone is first extruded along the Z-axis from the Bip01 Head bone in Edit Mode, then under the square icon ("Editing"), under "Armature Bones", make sure that the "Con" button for that new bone is unclicked. This makes it so that the new bone, when animated, does not make the Bip01 Head bone move or rotate also. You'll need to parent the "unskinned" helmet mesh to this new "hood" bone, and export the skeleton, with this hood mesh under the Bip01 Hood bone (or whatever name). You'll need to assign this custom skeleton to your NPC(s) who'll be using the pose. You then just animate the Bip01 Hood bones, to have the hood come off the head as the hands visually are grasping it and taking it off, then you can quickly scale the Bip01 Hood bone to zero, to make it disappear, as if it was put in the NPC's inventory.

To do this, though, you'll have to make your animation extended, so that it animated showing the hood coming off, the hand with hood moving down to the side, and then the hood scaling to zero.

Koniption
User avatar
Ymani Hood
 
Posts: 3514
Joined: Fri Oct 26, 2007 3:22 am

Post » Sat Feb 19, 2011 1:55 am

ok, let's see, where to start.

I'm using
Blender v. 2.49 b (why so low you may ask, well, that's the newest version I could find that supported Nif-import/export)
Nifskope v. 1.0.22
Python26
PYFFI v. 2.1.9

Thank you for the lock-trick, didn't know about that screen. (I did know about LocRot (i button), but I had forgotten to select all bones before I did it last update, as you said.
About the skeleton, I'm pretty sure it's not the 1stP skel, I got it from "_male" (still, it might be). Also, all my skels from "_male" has the camera node. Just saying. Nevertheless I did try to remove it from the pose (making it so it shouldn't change the cameras position or rotation), but I still have the same problem. And my last pose definitly used the 3rdP skel, and the exact same bug accured then.

Everytime you post, I learn something new about Blender and animation, but it doesn't seem to help with the problems I'm facing, but it does makes me faster, better and more accurate with Blender (creating the pose and getting it ingame on the first try).

You've gotten the pose ingame, how does the head look when you walk away from the NPC? Have you tried it on the player? And didn'y you get the fall down into the ground bug? (as I tried your version and I still get it).

Nocturnals gray cowl is in a helm object, it's equiped like any other helm, just to make it easy. It's not supposed to be an animation, it's a pose, the helm is just a prop. :wink:

OK, so I've been working on it (as I've been for a time now), and I found out that by deleting Bip01 and Bip01 NonAccum from the pose (not altering them) removes the bug with the char falling through the ground.

Then one thing is covered... Still need to fix the head...
User avatar
Latisha Fry
 
Posts: 3399
Joined: Sat Jun 24, 2006 6:42 am

Post » Sat Feb 19, 2011 10:11 am

[snip...]
You've gotten the pose ingame, how does the head look when you walk away from the NPC? Have you tried it on the player? And didn'y you get the fall down into the ground bug? (as I tried your version and I still get it).

Nocturnals gray cowl is in a helm object, it's equiped like any other helm, just to make it easy. It's not supposed to be an animation, it's a pose, the helm is just a prop. :wink:

OK, so I've been working on it (as I've been for a time now), and I found out that by deleting Bip01 and Bip01 NonAccum from the pose (not altering them) removes the bug with the char falling through the ground.

Then one thing is covered... Still need to fix the head...


It has been a long time since I've had to force an idle animation. So I think I did the forcing of the idle, wrong, when I tested it. [And you're right, the 3rd person skeleton does have a Camera01 bone.... :facepalm: (whoopsie) ]

So I didn't get the NPC to do the pose while I stood away from them and watched them. I had to talk to them first, which seemed to kick the pose into action. He looked straight at me as he did the pose, but didn't seem to fall into the ground. When I left conversation with him, he didn't do the pose. Had to talk to him each time I wanted to see the pose. I did not try it on the player; I've never experimented with getting the player to do idle poses, so I'm not sure if anything is different for that, or if it even is supposed to work.

I followed the force idle instructions here:

http://cs.elderscrolls.com/constwiki/index.php/Forcing_Idle_Animations

...but like said, the actor did not do the pose when they came into view and I saw them. Had to talk to them first, oddly enough.

Ah, nice work on finding out about the Bip01 and NonAccum bones. They often cause trouble, because for different animations and when it comes to playable races vs. creatures, their data often needs to be set up differently. I'm currently working on my first custom playable race; up til now, I had only worked on creatures. So I'm still learning stuff about playable races and animations, too.

When you next test your pose, be sure to stand away from the test NPC, so that they don't see you and look straight at you. If the head still looks weird, then I dunno at this point, and my brain is stalling at coming up with further answers, at least for now. Also, go to their "AI" tab, and make their "Energy" a value such as "5". The lower the "Energy" value, the more often the character will choose an idle animation. At first I thought the more Energy that a character had, the more they'd do idles - but the opposite is true. So watch out for that.

Koniption
User avatar
keri seymour
 
Posts: 3361
Joined: Thu Oct 19, 2006 4:09 am

Post » Sat Feb 19, 2011 3:10 am

I'm using the pose on the player (by replacing my pose with a pose in Gomas Animation mod), that way I can use the anim on the player, which it's suppose to.
I just woundered if the head is bugged on your part (but if you're watching it that way, I don't think you would notice).
User avatar
Esther Fernandez
 
Posts: 3415
Joined: Wed Sep 27, 2006 11:52 am


Return to IV - Oblivion