Comments (4)
btw does your library capable of producing binary fbx directly from unity without the need to use UnityFBXExporter.FBXExporter.MeshToString
?
from fbxwriter.
I also had to add a special case here to read byte
Line 103 in 53d9479
that solved all the exceptions.
but I still cannot open the generated file even though I can open the original ascii
fbx files.zip
can you please tell me what I should do?
.
from fbxwriter.
I wrote this code to understand where is the problem:
var doc = FbxIO.ReadAscii(dir + file1);
string fileA = "testA_" + file1;
FbxIO.WriteAscii(doc, dir + fileA);
doc = FbxIO.ReadAscii(dir + fileA);
string fileB = "testB_" + file1;
FbxIO.WriteBinary(doc, dir + fileB); // i can't open this
doc = FbxIO.ReadBinary(dir + fileB);
FbxIO.WriteAscii(doc, dir + "testC_" + file1); // i can open this
the code does not throw an exception (after the fixes I made to FbxWriter).
I tried view the files using FBX viewer https://overbits.herokuapp.com/fbxgltf/
using the FBX viewer above I can open the ascii outputs but not the binary outputs.
if I read the binary output and write it again as ascii then I can view it again.
blender gave me the following error when I opened the binary fbx file
from fbxwriter.
I converted the ascii fbx to binary fbx with this tool and it worked:
https://github.com/BobbyAnguelov/FbxFormatConverter
unfortunately, it's in c. I need in c#
I ran this test to gain more debugging info:
string file1 = "RoadMediumNode.binary.fbx"; // can open this
var doc = FbxIO.ReadBinary(dir + file1);
string fileA = "testA_" + file1;
FbxIO.WriteBinary(doc, dir + fileA); // can open this
doc = FbxIO.ReadBinary(dir + file1);
string fileB = "testB_" + file1;
FbxIO.WriteAscii(doc, dir + fileB); // can open this
doc = FbxIO.ReadAscii(dir + fileB);
FbxIO.WriteBinary(doc, dir + "testC_" + file1); // can' open this
read working binary fbx -> write as binary fbx -> works
read working ascii fbx created FbxFormatConverter -> write as binary fbx -> does not work.
conclusion:
I am suspecting that the bug is an incompatibility between ascii reader and binary writer.
Note that I ran these tests after applying the fixes I suggested in the comments bellow
from fbxwriter.
Related Issues (8)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fbxwriter.