stride icon indicating copy to clipboard operation
stride copied to clipboard

[WIP][Asset] Unified 3D asset importer (on behalf of Noa7/Noah7071)

Open Eideren opened this issue 1 year ago • 1 comments

PR Details

Replaces the C++/CLI FBX importer with a managed c# one using Assimp https://opencollective.com/stride3d/projects/fbx-import-cpp-to-c-sharp Fix #1923

Types of changes

  • [ ] Docs change / refactoring / dependency upgrade
  • [ ] Bug fix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)
  • [ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • [ ] My change requires a change to the documentation.
  • [ ] I have added tests to cover my changes.
  • [ ] All new and existing tests passed.
  • [ ] I have built and run the editor to try this change out.

Eideren avatar Feb 20 '24 17:02 Eideren

Thanks again @Noah7071 - didn't go too deep into the review yet, just did a quick test using the animation sample. It mostly works, just a couple of things to iron out; Looks like right now the fbx scale and or axis is not taken into account, here's the scale as is with the PR: image And what it should be: image Running the sample makes the character run sideways, likely because of the custom axis of rotation / coordinate basis embedded in that particular fbx: image

Eideren avatar Feb 20 '24 19:02 Eideren

Some files not needed, like the workspace.db (couldn't add a comment to that binary file).

Done, Reverted.

Noah7071 avatar Feb 21 '24 12:02 Noah7071

Thanks again @Noah7071 - didn't go too deep into the review yet, just did a quick test using the animation sample. It mostly works, just a couple of things to iron out; Looks like right now the fbx scale and or axis is not taken into account, here's the scale as is with the PR: image And what it should be: image Running the sample makes the character run sideways, likely because of the custom axis of rotation / coordinate basis embedded in that particular fbx: image

Thanks for laying this out @Eideren. Changed to default 1 unit file = 1 stride Unit as default as discussed, tested behavior cross Maya & Blender for consistency!

Noah7071 avatar Feb 21 '24 14:02 Noah7071

Stride.Importer.3D and Stride.Importer.Assimp are duplicated, Can Stride.Importer.Assimp be deleted?

Stride.Importer.FBX is no longer used. Can it be deleted?

Wolffy101 avatar Feb 22 '24 02:02 Wolffy101

Stride.Importer.FBX

Stride.Importer.3D and Stride.Importer.Assimp are duplicated, Can Stride.Importer.Assimp be deleted?

Stride.Importer.FBX is no longer used. Can it be deleted?

Hi @Wolffy101 , which file have these references ?

Noah7071 avatar Feb 22 '24 03:02 Noah7071

Stride.Importer.FBX

Stride.Importer.3D and Stride.Importer.Assimp are duplicated, Can Stride.Importer.Assimp be deleted? Stride.Importer.FBX is no longer used. Can it be deleted?

Hi @Wolffy101 , which file have these references ?

No. I mean delete Stride.Importer.FBX and Stride.Importer.Assimp project folders

Wolffy101 avatar Feb 22 '24 03:02 Wolffy101

Stride.Importer.FBX

Stride.Importer.3D and Stride.Importer.Assimp are duplicated, Can Stride.Importer.Assimp be deleted? Stride.Importer.FBX is no longer used. Can it be deleted?

Hi @Wolffy101 , which file have these references ?

No. I mean delete Stride.Importer.FBX and Stride.Importer.Assimp project folders

Oh yes surely!

Noah7071 avatar Feb 22 '24 03:02 Noah7071

Stride.Importer.FBX

Stride.Importer.3D and Stride.Importer.Assimp are duplicated, Can Stride.Importer.Assimp be deleted? Stride.Importer.FBX is no longer used. Can it be deleted?

Hi @Wolffy101 , which file have these references ?

No. I mean delete Stride.Importer.FBX and Stride.Importer.Assimp project folders

Oh yes surely!

The the two unnecessary projects mentioned should be gone in latest, thanks for pointing this out!

Noah7071 avatar Feb 22 '24 06:02 Noah7071

UPDATE: Added support of multiple animations, upon import(Model or Animation), for each animation clip in source file, importer will create a unique animation asset! Below is a test project demonstrating this, also added the source FBX file containing three animation which in scene converts to three individual stride animation assets!

https://github.com/Noah7071/Stride_MultipleAnim_Test

P.S. Recommend clear Local AppData temp Stride files to avoid compiling error

Noah7071 avatar Feb 22 '24 06:02 Noah7071