OpenSAGE / OpenSAGE.BlenderPlugin

A Westwood 3D Blender plugin. Imports & exports the W3D/W3X format to/from Blender.
https://opensage.github.io
GNU Lesser General Public License v3.0
50 stars 18 forks source link

Support W3D_CHUNK_VERTICES_2 and W3D_CHUNK_NORMALS_2 #243

Closed nkx111 closed 1 year ago

nkx111 commented 1 year ago

Write the second group of vertices/normals which translate according to the extra bone group.

This PR also scales up bone weight if not add up to 100%.

Tarcontar commented 1 year ago

@nkx111 thank you for your work! Could you please rebase this and maybe also add a corresponding unittest similar to the existing ones?

Tarcontar commented 1 year ago

@nkx111 Hi, thank you for updating the branch. There are a few tests that fail with your changes. Could you please have a look at them and try to fix them?

nkx111 commented 1 year ago

Hi @Tarcontar, I updated the tests and hopefully they are fixed. There are three items which are changed:

nkx111 commented 1 year ago

I don't know why the updated size calculation with the second vertics group leads to failure in test_roundtrip. So I reverted those commits, and pushed another fix. Now it still uses the old mesh-size calculation, but won't write the second vertics group in the test. The tests are successful on my local computer.

Tarcontar commented 1 year ago

Hi, we definetely need the second vertices group in the size calculation. Please readd this otherwise the created mesh files will be incorrect. If you cant get the test_roundtrip to work i will have a look then.

nkx111 commented 1 year ago

Hi @Tarcontar, I think the size issue has been fixed.