Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
830 views
in Technique[技术] by (71.8m points)

c# - How can I load FBX file in Unity runtime?

I am on a hololens project. My boss says, load the fbx file at runtime (we use unity). Our fbx file changes at runtime, so we must reload it (fbx is change from 3dMAx).

I tried the AssetBundle, but I can't create Assetbundle files without unity or unity editor mode. As far as I know, only resource (in Project tab) can insert assets to assetbundle. If I can build Assetbundle file by fbx file without unity project, I can do all.

To sum it up: I need way how to load fbx in runtime without unity resource. If I make fbx asset to assetbundle in runtime (fbx is not belong in project tab), it's ok.


edit)

Using trilib asset is the best way. I try make own FBX loader, it's too difficult and a big job. I think trilib is not perfect, but it is the best.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You could consider converting FBX into glTF, which Unity can load at runtime with UnityGLTF tools.

https://github.com/KhronosGroup/UnityGLTF


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
...