The y rotation of an object I created in babylonjs is 3 and it looks to the left, but when I open this object in unity, when I give it a time and y rotation of 3, it looks to the right with little change in its rotation.
Besides, I give 3 units as the scale value of an object I created in babylonjs and its size is 14m, but when I give 3 units of scale in unity, its size becomes 35m. Please help if you have any knowledge on the subject.
In what format are you exporting your Babylon object? This might have to do with converting to a differently handed coordinate system during export.
Yes, that must be the answer. I could add to it that the “little change in rotation”, likely comes from that the value of 3 (in BJS units) should in fact be Math.PI (3.141593), so once inverted it should look as exactly the opposite. If it is a left-handed VS right-handed issue then probably you didn’t notice that the Z-axis likely also has been set to -Z.
Nesnem glb formatında ancak dışa aktarmak gibi bir durum yok. Glb dosyalarım tek bir klasör içerisinde. Bu glb dosyalarını hem unity de hemde babylonjs de oluşturduğum sahnede gösteriyorum.
Unfortunately this doesn’t work. I gave a little more detail about my problem. I hope I was able to explain.
Thanks for the details but this got me even more confused.
You said you are CREATING the object in BJS first. So it must be a native babylon.js mesh; not an imported object, is it? If so, you have no other choice than to export it (either the scene or the mesh) from BJS, yes? What method are you using to end-up with your .glb?
About the size/scale, I can give you a clue, I believe. 1 unit in BJS does not == 1 unit in dcc or exported format. For example, I mostly use cinema4D. When I export say a 1m. object to an .obj format for import in BJS, in the export format I do not use a scale of 100cm. I export it to 250cm. And if I model it at twice the size, I export it at 125cm. In the end, applying a multiplier of 2.5 makes for an identical size and that seems to apply to your case as well (14*2.5 = 35). In any case surely, the scaling (factor) applied to an object size is the same. An object upscaled 3 times in BJS is upscaled 3 times on export (As far as I know and could experience). It’s the original unitSize that might be different.
Now, if the object is actually NOT a native Babylon.js mesh, but just an imported .glb, then the left-handed VS right-handed rule MUST APPLY here. In BJS, you should have a root node on this imported object that makes for the conversion.
To make this clearer, could you just list the operations you are doing STEP-BY-STEP. If you could also add a PG for the BJS part, that would be even better.
I’m sorry but I need you to answer in English.