When exporting the glTF file with Babylon.js Inspector, the polygon is inverted

Recommended Posts

I tried exporting glTF file using Inspector of Babylon.js Sandbox. However, it seems that the polygon is inverted and displayed.

The version of Babylon.js is v3.3.0-alpha.11.

I think that it is because FRONT_FACE is not CCW but CW.




Share this post

Link to post
Share on other sites

Hi @cx20.  I made a change yesterday to handle correcting the winding order . The validation issue seems to relate to a node with no children.  I will check for that condition and not export that node.  Thanks again for flagging these issues!

Share this post

Link to post
Share on other sites

I confirmed that this problem was solved with the inspector of Babylon.js Sandbox.

The version of Babylon.js is v3.3.0-alpha.12.


However, downloading the latest version of babylon.glTF2Serializer.js from the repository of Babylon.js and testing it locally did not seem to work properly for some reason.

The version of Babylon.js is v3.3.0-alpha.12.





There should be some difference, but I have not yet arrived at the cause:(



Edited by cx20
Unnecessary images deleted

Share this post

Link to post
Share on other sites

I understood what kind of situation it will go wrong.

I am changing the scale of the model in the sample program displaying my glTF, but it seems that exporting can not be performed correctly if it is not 1.0.

NG :

OK :

However, I do not know how to fix it. Are there any advice?

parentMesh.scaling = new BABYLON.Vector3(modelScaling.x * scale, modelScaling.y * scale, modelScaling.z * scale);


Share this post

Link to post
Share on other sites

Hi @cx20, I couldn't find a reason why your code would not work, but when checking your links again, the issue seems to have been resolved.  Are you able to confirm that on your end?

Share this post

Link to post
Share on other sites

Hi @kcoley, Hmm. I tried it again, but it seems to reproduce.

It reproduced with the following combination.

Windows 10 Version 1803 + Chrome 67.0.3396.99 
Windows 10 Version 1803 + Firefox 61.0.1

The reproduction procedure is as follows.

1. Go to the following URL.

Set the scale parameter to 10.

2. Check "Debug" on the control panel


3. Select glTF menu from the inspector window.

4. Click the "Export GLB" button.


5. Download the export file.


6. Drag and drop the glb file into the glTF Viewer.


7. Please look at the display result.



Share this post

Link to post
Share on other sites

@kcoley Thank you for fixing Issue.

However, it seems that the latest version of glTF Exporter is not created by nightly build. This is because the timestamp is in a state one day ago.

Could you check if the latest version of glTF Exporter was created? release/serializers

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.