Pab144 Posted July 22, 2018 Share Posted July 22, 2018 Hey there Babylonians, I'm having an issue with the gLTF exporter for 3dsMax 2017 and FUR MATERIAL, It would seem that when I add the FUR MATERIAL to the mesh exported using gLTF the faces get flipped or something. I tried exporting the same geometry using just the .babylon file format and it worked nicely picture below. However when I export with .gltf format it looks like this. I've tried flipping the faces inside of 3dsmax but so far no luck. Also I've noticed that the gltf exporter rotated my mesh 180 degrees on the y-axis for some reason. Any help or advice would be of great help. Regards, Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 23, 2018 Author Share Posted July 23, 2018 I did some "testing" with 3dsmax primitive shapes to see if the issue is was just a geometry problem with my mesh, bu the error came up again. I'm trying to use BJS for architectural presentations and so far it's been real great. I'm trying to build the scenes and export them from 3dsmax using .gltf to use pbr materials for better realistic results but my solution for generating realistic grass doesn't export well. Here's a pic of the scene using .babylon file format and Standard Materials. Any help or guidance would be greatly appreciated. Jaskar 1 Quote Link to comment Share on other sites More sharing options...
Guest Posted July 23, 2018 Share Posted July 23, 2018 This is really beautiful Do you know that PBR works in Babylon.js as well? But nevermind, regarding your glTF issue let me ping @noalak Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 23, 2018 Author Share Posted July 23, 2018 I know the .babylon supports Physical Material form 3DsMax, but I was trying out .gLTF for some of the file size advantages. Quote Link to comment Share on other sites More sharing options...
Jaskar Posted July 24, 2018 Share Posted July 24, 2018 Hey @Pab144 , @noalak is sick, so someone else in the exporter team is currently working on this issue. We'll let you know about the progress, or if we have any question. Quote Link to comment Share on other sites More sharing options...
rlouvat Posted July 24, 2018 Share Posted July 24, 2018 Hi Pab144, I'm looking at your issue :). Can you tell me on which exporter version you are working ? Also can you provide me a sample ? So I can test on my side too. Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 24, 2018 Author Share Posted July 24, 2018 Hey @Jaskar, I appreciate the help, if there's anything I can do to help let me know. Regards, Quote Link to comment Share on other sites More sharing options...
Jaskar Posted July 24, 2018 Share Posted July 24, 2018 @Pab144 Can you tell me on which exporter version you are working ? Also could you provide a sample please ? So we could test on our side too. Feel free to PM me if you don't want to share your assets. Edit : I posted this awaiting the @rlouvat post. rlouvat 1 Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 24, 2018 Author Share Posted July 24, 2018 Hey guys, I'll send you a link to the files and assets via PM. I'm using 3dsMax 2017 so my exporter version of max2babylon v.1.2.18 Thank you so much for the help! Quote Link to comment Share on other sites More sharing options...
rlouvat Posted July 25, 2018 Share Posted July 25, 2018 Hi @Pab144 You are right there is a 180 degrees on the y-axis rotation on the glTF export. It is due to the change of the coordinate system (from 3DS Max to Babylon and from Babylon to glTF). Plus changing a mesh material doesn't work (even if it's not a fur one). I suspect it is related to the uv... I created a issue on github. Here is the link https://github.com/BabylonJS/Exporters/issues/276 As soon as I found something, I will tell you. Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 25, 2018 Author Share Posted July 25, 2018 Cool thanks for the all help man, I'm glad you guys are on it. GameMonetize 1 Quote Link to comment Share on other sites More sharing options...
rlouvat Posted July 26, 2018 Share Posted July 26, 2018 Hi @Pab144 The issue is related to the loader so I created a new issue on github in the right section: https://github.com/BabylonJS/Babylon.js/issues/4833 Sorry I didn't find a solution nor a workaround yet. Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 27, 2018 Author Share Posted July 27, 2018 No big guys, keep up the great work, I appreciate all the help. Quote Link to comment Share on other sites More sharing options...
rlouvat Posted July 30, 2018 Share Posted July 30, 2018 Hi @Pab144 Did you see the answer of bghgary on github? He said that you have to set the material sideOrientation to ClockWiseSideOrientation. So in your code you should add something like this: grass.material = grassMaterial; grass.sideOrientation = BABYLON.Material.ClockWiseSideOrientation; var quality = 30; var shells = BABYLON.FurMaterial.FurifyMesh(grass, quality); for (var i = 0; i < shells.length; i++) { shells[i].material.sideOrientation = BABYLON.Material.ClockWiseSideOrientation; } Quote Link to comment Share on other sites More sharing options...
Pab144 Posted July 31, 2018 Author Share Posted July 31, 2018 Hi @rlouvat, I Just tried the solution, and it worked quiet well see pic But when I move around in the space and rotate the camera it flashes black. Any ideas? Quote Link to comment Share on other sites More sharing options...
Guest Posted July 31, 2018 Share Posted July 31, 2018 Can you repro in the PG? Quote Link to comment Share on other sites More sharing options...
rlouvat Posted August 1, 2018 Share Posted August 1, 2018 Hi @Pab144 As I was unable to reproduce the bug in the playground, I though that it was related to some dependencies. So I replace the scripts in the index.html <script type="text/javascript" src="babylon/babylon.custom.js"></script> <script type="text/javascript" src="babylon/babylon.inspector.bundle.js"></script> <script type="text/javascript" src="babylon/babylon.furMaterial.min.js"></script> by <script src="https://preview.babylonjs.com/babylon.js"></script> <script src="https://preview.babylonjs.com/inspector/babylon.inspector.bundle.js"></script> <script src="https://preview.babylonjs.com/loaders/babylonjs.loaders.min.js"></script> <script src="https://preview.babylonjs.com/materialsLibrary/babylonjs.materials.min.js"></script> And it works :) Can you tell me if it's 0k for you? Quote Link to comment Share on other sites More sharing options...
Pab144 Posted August 2, 2018 Author Share Posted August 2, 2018 Hi @rlouvat, Yup that fixed it man. it's perfect now, thank you so much for all the help guys it's been invaluable. Cheers to you all! Quote Link to comment Share on other sites More sharing options...
rlouvat Posted August 2, 2018 Share Posted August 2, 2018 Hi @Pab144 You are welcome. Thanks to you I learned new things about gltf and the fur texture Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.