Archived

This topic is now archived and is closed to further replies.

Java port of Skeletal Animation Tut

This topic is 4959 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi first post, I am currently trying to port the excellent Brett Porter Skeletal Animation Tutorial from C++ to Java using OpenGL bindings. I have completed the loader but when I try to animate the Model, the Model arms,legs, and body seem to have been strecthed. Also the head seems to be coming out the models head. I have looked at my code and I have seemed to hit the Coders equivalent of writers block with this problem. Heres what the model looks like with no Animation no Animation. And heres what the model looks like with Animation Animation. Any Ideas would be greatly appreciated Thanks in advance Brian

Share this post


Link to post
Share on other sites
Reverse the loading of rotation and translation keyframes - it should be translation before rotation. The example has them backwards. I had the same exact problem, and it took me several days to figure out what was going wrong.

Share this post


Link to post
Share on other sites
Thanks for the reply I tried your Idea out, and unfortunally it didn't work. I fooled around with my code a wee bit taking out lines and putting print statements and I found out if I take out the line that sets the initial Relative Matrix in the Setupjoints method I get this

link

As you can see my Model is doing a good impression of Michael Jackson or somebody like that

Could it be a problem with my Translation Method in My Matrix class ?


public void setTranslation(float[] translation){
m_matrix[12] = translation[0];
m_matrix[13] = translation[1];
m_matrix[14] = translation[2];
}


My Matrix class has an Array of 16 floats m_matrix.


Thanks again
Brian


[edited by - Big_Bear_Scot on May 18, 2004 5:18:39 PM]

Share this post


Link to post
Share on other sites