Jump to content

  • Log In with Google      Sign In   
  • Create Account


#Actualuglybdavis

Posted 27 May 2013 - 06:11 AM

@schrompf 

I spent all day coming to that conclusion. And i just glanced at the docs again, NO IDEA how i missed that. I feel like a complete retard.

I'm planning to use assimp as a "converter" to a custom format, which does not have pre-multiplied tracks.

The displaying of animation bit is just to make sure i'm loading everything into my data structures correctly 

 

@Zaoshi Kaba 

I have two vertex buffers, a "data" buffer and a "scratch" buffer.

At the beginning of the program i take the data buffer and fill it with the skin position of every vertex.

At this point it can be used to render a static mesh, the scratch buffer is empty.

Then the first time an animation is attached to the mesh i multiply every vertex in the data buffer by the offset matrix.

From now on the data buffer is never rendered, only the scratch buffer is.

Every frame i update the skeleton, and multiply the the data buffer by the world position of every joint INTO the scratch buffer

Then i render the scratch buffer

The format i'm planning to export to does not store the premultiplied offset, but rather relies on the user to figure that out at load time; so the matrix is not in any of my data structures.

 

Like i said, the animations are playing correctly now, there just seems to be some swimming going on. Nothing a few more man-hours shouldn't be able to fix.

In case anyone is wondering what kind of ass-backwards format i'm trying to export to, it's for extra credit for a class ;) Pretty sure the format was made up to make my life hell.

 

But yeah, if anyone has any ideas about the swimming before i waste another three hours please let me know.

It looks like it has something to do with the data still, i'm pretty sure that i've correctly removed the joint transform from the animation tracks.


#3uglybdavis

Posted 27 May 2013 - 06:11 AM

@schrompf 

I spent all day coming to that conclusion. And i just glanced at the docs again, NO IDEA how i missed that. I feel like a complete retard.

I'm planning to use assimp as a "converter" to a custom format, which does not have pre-multiplied tracks.

The displaying of animation bit is just to make sure i'm loading everything into my data structures correctly 

 

@Zaoshi Kaba 

I have two vertex buffers, a "data" buffer and a "scratch" buffer.

At the beginning of the program i take the data buffer and fill it with the skin position of every vertex.

At this point it can be used to render a static mesh, the scratch buffer is empty.

Then the first time an animation is attached to the mesh i multiply every vertex in the data buffer by the offset matrix.

From now on the data buffer is never rendered, only the scratch buffer is.

Every frame i update the skeleton, and multiply the the data buffer by the world position of every joint INTO the scratch buffer

Then i render the scratch buffer

The format i'm planning to export to does not store the premultiplied offset, but rather relies on the user to figure that out at load time; so the matrix is not in any of my data structures.

 

Like i said, the animations are playing correctly now, there just seems to be some swimming going on. Nothing a few more man-hours shouldn't be able to fix.

In case anyone is wondering what kind of ass-backwards format i'm trying to export to, it's for extra credit for a class ;) Pretty sure the format was made up to make my life hell.

 

But yeah, if anyone has any ideas about the swimming before i waste another three hours please let me know.

It looks like it has something to do with the data still, i'm pretty sure that i've correctly removed the joint transform from the animation tracks.

 

Edit, it looks like each joint is first being rotated, then translated... I'm not sure what to make of that....


#2uglybdavis

Posted 27 May 2013 - 05:24 AM

@schrompf 

I spent all day coming to that conclusion. And i just glanced at the docs again, NO IDEA how i missed that. I feel like a complete retard.

I'm planning to use assimp as a "converter" to a custom format, which does not have pre-multiplied tracks.

The displaying of animation bit is just to make sure i'm loading everything into my data structures correctly 

 

@Zaoshi Kaba 

I have two vertex buffers, a "data" buffer and a "scratch" buffer.

At the beginning of the program i take the data buffer and fill it with the skin position of every vertex.

At this point it can be used to render a static mesh, the scratch buffer is empty.

Then the first time an animation is attached to the mesh i multiply every vertex in the data buffer by the offset matrix.

From now on the data buffer is never rendered, only the scratch buffer is.

Every frame i update the skeleton, and multiply the the data buffer by the world position of every joint INTO the scratch buffer

Then i render the scratch buffer

The format i'm planning to export to does not store the premultiplied offset, but rather relies on the user to figure that out at load time; so the matrix is not in any of my data structures.

 

Like i said, the animations are playing correctly now, there just seems to be some swimming going on. Nothing a few more man-hours shouldn't be able to fix.

In case anyone is wondering what kind of ass-backwards format i'm trying to export to, it's for extra credit for a class ;) Pretty sure the format was made up to make my life hell.

 

But yeah, if anyone has any ideas about the swimming before i waste another three hours please let me know.

It looks like it has something to do with the data still, i'm pretty sure that i've correctly removed the joint transform from the animation tracks.


#1uglybdavis

Posted 27 May 2013 - 04:52 AM

@schrompf 

I spent all day coming to that conclusion. And i just glanced at the docs again, NO IDEA how i missed that. I feel like a complete retard.

I'm planning to use assimp as a "converter" to a custom format, which does not have pre-multiplied tracks.

The displaying of animation bit is just to make sure i'm loading everything into my data structures correctly 

 

@Zaoshi Kaba 

I have two vertex buffers, a "data" buffer and a "scratch" buffer.

At the beginning of the program i take the data buffer and fill it with the skin position of every vertex.

At this point it can be used to render a static mesh, the scratch buffer is empty.

Then the first time an animation is attached to the mesh i multiply every vertex in the data buffer by the offset matrix.

From now on the data buffer is never rendered, only the scratch buffer is.

Every frame i update the skeleton, and multiply the the data buffer by the world position of every joint INTO the scratch buffer

Then i render the scratch buffer

The format i'm planning to export to does not store the premultiplied offset, but rather relies on the user to figure that out at load time; so the matrix is not in any of my data structures.

 

Like i said, the animations are playing correctly now, there just seems to be some swimming going on. Nothing a few more man-hours shouldn't be able to fix.

In case anyone is wondering what kind of ass-backwards format i'm trying to export to, it's for extra credit for a class ;) Pretty sure the format was made up to make my life hell.

 

But yeah, if anyone has any ideas about the swimming before i waste another three hours please let me know.

I'll post the final code once the swimming is solved, in case anyone in the future is interested.


PARTNERS