FBX IO: better default settings for anim curve preservation and pipeline integration #105172
No reviewers
Labels
No Label
Interest
Animation & Rigging
Interest
Blender Cloud
Interest
Collada
Interest
Core
Interest
Documentation
Interest
Eevee & Viewport
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
Import and Export
Interest
Modeling
Interest
Modifiers
Interest
Nodes & Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds, Tests & Devices
Interest
Python API
Interest
Rendering & Cycles
Interest
Sculpt, Paint & Texture
Interest
Translations
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Meta
Good First Issue
Meta
Papercut
Module
Add-ons (BF-Blender)
Module
Add-ons (Community)
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender-addons#105172
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "Roland-Vyens:fbx_fix_default_settings"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem:
Animation curves gets detroyed with current default anim export settings: blender/blender-addons#105058
Enable "NLA Strips" and "All Actions" will cause error if you want to import your camera or other stuff to Unreal Engine as well as other DCC software for some of them doesn't support multiple anim channels in 1 fbx file.
Import animation won't align with the desired frame range (offset 1 frame).
Solutions:
Just set the simplify to 0.005, the cam will be perfect with no shift at all, also the unkeyed properties will not get force baking keys while the simplify is set to 0.
The "NLA Strips" and "All Actions" should be disabled by default.
set default import offset to 0 for animations align with their desired frame number.
Wouldn't mind second opinion (@Mysteryem maybe?), but I think changing defaults like that is not really a good thing. It will 'fix' some issues in some cases, but break things in others.
That's the reason why we do have presets, so that default behaviors can be tweaked as needed for each pipeline.
From a user perspective, I personally think 1 and 3 is OK though... Other DCC software's default import/export settings for animation generally tend not to modify the anim offset or automatically simplify animation curves.
As a volunteer Q&A guy in Chinese blender community, I often see a lot questions about exporting fbx not working as expected or animation curves changed, each time I have to teach them modify simplify factor and turn off NLA and All Action over and over again… so I think change these default settings can make the newbies' experience instantly better without ever needing to ask a question. It would be really nice if you consider about solution 1 and 2 together 😄 Or maybe add 2 toggle for simplify and force baking all unkeyed property? But that's some good amount of work to deal with…
I'll preface this by saying that I don't personally work with animation much and what I do is pretty much all humanoid animations from external sources or simple humanoid animations I've created myself in Blender.
For humanoid animations that I occasionally work with, I think the default
Simplify
setting is fine, I don't think I've ever had to adjust it, and Unity, which I'm using, resamples imported FBX animation curves and performs keyframe reduction by default anyway.The provided example case seems to be one that specifically requires high precision, in which case I think it would make sense that the default
Simplify
setting is not suitable, but I'm not sure that alone that means the default value needs adjusting.Also, as brought it up before in #104978, comparing the animations in a Blender exported FBX, that has been re-imported, to its original .blend is not very useful because Blender and FBX have fundamentally different ways of storing Object transforms such that some information will always be lost in the conversion to/from FBX. The simplification step in particular happens after the conversion to FBX tranforms, so there's also no simple way to directly compare the before and after of the simplification step.
I don't actually know how to use NLA and there's a fairly old bug (#66272) with exporting shape key animations, so I have both of these disabled in my export presets. I think disabling both "NLA Strips" and "All Actions" could make the default export simpler, but I don't personally have much use for either of the options, so I'm not familiar with their uses.
I think this is a similar argument to the 'arrays start at 0' vs 'arrays start at 1' argument of programming languages. Blender's default startup file has a 250 frame animation that starts on frame
1
and ends on frame250
, so I think that the default import offset of1
makes sense for Blender. Unless there's some other issue with the default import offset?Ideally, if it produces good results, I'd like to replace the current simplification algorithm with using the same functions as the F-Curve decimation operator. I've been trying to figure out how to convert Blender keyframe tangents to FBX so that the Allowed Change mode of F-Curve decimation could be used since its more similar in design to the current simplification algorithm than the Ratio mode, but I've not had any luck getting the tangents to work so far.
This camera problem was discovered when we just start using blender in our pipeline. At that time we are doing a project that use blender to render character and unreal engine to render background, at compositing stage of that project, I see big shift in position of the 2 renders, and at that time I didn't know it was because simplify, so I had to align those frames by hand.
It do looks fine after imported into unreal engine, but when I combine blender render with unreal render, things became super obvious. So I definitely recommend to tweak the default simplify factor, less is better, even 0 should be considered as default value in terms of production robustness. @Mysteryem
I also provide a simplify 0.01 fbx file, it perfectly aligns with blender original camera animation curve. Also no problem in unreal engine at all.
About the "NLA Strips" and "All Actions" options, afair these were requested and are used by artists creating assets for games. They usually have a collection of actions e.g. for each character, and need to get them all with their assets.
Regarding changing defaults: in general, there needs to be a very good reason to change defaults of existing settings. Mainly because changing default of an otherwise unmodified feature will break people's pipelines, without any way to work around it or even warn about it.
Even when improving or re-working a feature, we try to keep the default behavior as close as possible from the previous one, for the same reasons.
Thanks for the PR, but presets are the recommended way to tweak the IO behavior for any specific requirements.
Pull request closed