AsoboStudio / glTF-Blender-IO-MSFS

Apache License 2.0
139 stars 28 forks source link

Hiding an object that takes a long time to export doesn't affect the export time, should it? #288

Open tml1024 opened 10 months ago

tml1024 commented 10 months ago

Current Behavior

I have a Blender model in progress where I exaggerated the complexity of one part a lot (the jet engine), just for fun. Put way too much detailed geometry and modifiers into it. That makes the export very slow.

Now, if I hide the jet engine object hierarchy, the export is still as slow. Only if I delete the jet engine object hierarchy completely the export speed returns to what it was before I went crazy on the engine.

Sadly I was not able to quickly distill the problem down to a minimal example, so this bug report is probably fairly useless. Unless it makes you think of something even without a concrete reproducer sample.

Expected Behavior

Hiding a complex object should reduce the time to export the model.

Steps To Reproduce

.

Environment

Blender 3.3.12, current glTF-Blender-IO-MSFS.

Anything else?

No response

ronh991 commented 10 months ago

Screen shot of your export settings, may help ASOBO. Does it have animations? armatures? single export via File/export or multi export?

tml1024 commented 10 months ago

I will get back to this in some days and add a minimal reproduction example.

y-khodja commented 10 months ago

Hello,

Have you tried tu use the preset panel to export your model by putting the object you want to hide in another collection and export only the collections you want ?

tml1024 commented 10 months ago

I will try that later. But this bug can have fairly low priority, the export time is bearable at the moment,

tml1024 commented 8 months ago

it turned out that the thing that affects the export time most is the "Always Sample Animations" toggle from the upstream Khronos exporter. Turning that off makes the export two orders of magnitude faster for me... (from about 1400 seconds to about 20 seconds).

I don't know if there are some MSFS add-ons for which that toggle must be on, but at least for my aircraft add-on at its current state it doesn't seem to be required. Perhaps might be good to add a line or two about it to the README. Anyway, this issue can probably be closed.

y-khodja commented 8 months ago

Hello,

The exported animations must be Linear thus exporting without "always sample animations" option may result in a glTF with non-linear animations. These animations are not interpreated in the game. You will need to have this option ticked to make it work.

Thank you for your report,

tml1024 commented 8 months ago

You mean that if an animation is non-linear, it will not show up at all in the game? So if an animation does show up, it is linear? So if all my animations do show up even if I have that option off, I can keep it off?

y-khodja commented 8 months ago

What i mean is that the animation need to be represented linearly in the glTF to be interpreated by the game later (see the glTF documentation here [https://registry.khronos.org/glTF/specs/2.0/glTF-2.0.html#animations](). If your animations do show up in the game it means that the Khronos exporter exported them linearly but i can't guarantee that it will work everytime.

lyonheart001 commented 4 months ago

This is good to know... I have had tremendous issues the past year with exports and animations. At one point, it took 2 weeks to get ailerons to animate. Nothing worked. Animations have been a huge problem. I too un-ticked my Sample Animations so I didnt have to wait 10 minutes for a model to compile when animations were working fine. But good to know that it needs this.

Speaking of animations, note that Asobo are starting to use 3 KF's instead of 100 KF's on things like ailerons and flaps, etc.