FBX: Materials missing from linked duplicates #104737

Closed
opened 2023-07-05 16:10:51 +02:00 by Thomas Barlow · 1 comment
Member

System Information
Operating system: Windows-10-10.0.19041-SP0 64 Bits
Graphics card: NVIDIA GeForce GTX 1060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 512.78

Blender Version
Broken: 3.6.0, 4.0.0
Worked: 3.5.1

Short description of error
Moved from blender/blender#109723
When exporting an object with linked data to FBX and importing into Unity, the material on the copied object no longer exists.

Exact steps for others to reproduce the error

  • Create a material on an object
  • use the ALT+D link to copy the object.
  • exporting to FBX
  • import into Unity (the material on the copied object no longer exists)

This is not a problem in Blender. The material on the copied object is still present, but when exporting to FBX, the material on the copied object no longer exists.


The attached no_mat.blend in a comment in the original issue has two cubes that share the same mesh and have the same materials. Exporting this as .fbx and importing the .fbx into Unity will result in the material being missing from one of the cubes:
image

For some reason, this exported .fbx actually works in FBX Review, but it's clear from looking at the code and the .fbx itself that the linked duplicates (aside from the first) are not being given any material slots (material to model connections).

Importing the exported .fbx back into Blender will not show any issues because the materials are imported into the mesh by default. Because the linked duplicates, aside from the first, have no material slots, the materials are imported into the mesh from the first linked duplicate and then the other linked duplicates result in a no-op when it comes to importing their materials.

**System Information** Operating system: Windows-10-10.0.19041-SP0 64 Bits Graphics card: NVIDIA GeForce GTX 1060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 512.78 **Blender Version** Broken: 3.6.0, 4.0.0 Worked: 3.5.1 **Short description of error** Moved from https://projects.blender.org/blender/blender/issues/109723 When exporting an object with linked data to FBX and importing into Unity, the material on the copied object no longer exists. **Exact steps for others to reproduce the error** - Create a material on an object - use the ALT+D link to copy the object. - exporting to FBX - import into Unity (the material on the copied object no longer exists) This is not a problem in Blender. The material on the copied object is still present, but when exporting to FBX, the material on the copied object no longer exists. --- The attached [no_mat.blend](https://projects.blender.org/attachments/ce0efe67-8ddd-49ca-825c-064c9c02124a) in a comment in the original issue has two cubes that share the same mesh and have the same materials. Exporting this as .fbx and importing the .fbx into Unity will result in the material being missing from one of the cubes: ![image](/attachments/8dca12f2-b56a-4e01-890b-2e733c4eb6ad) For some reason, this exported .fbx actually works in FBX Review, but it's clear from looking at the code and the .fbx itself that the linked duplicates (aside from the first) are not being given any material slots (material to model connections). Importing the exported .fbx back into Blender will not show any issues because the materials are imported into the mesh by default. Because the linked duplicates, aside from the first, have no material slots, the materials are imported into the mesh from the first linked duplicate and then the other linked duplicates result in a no-op when it comes to importing their materials.
2.6 KiB
Thomas Barlow added the
Type
Report
Priority
Normal
Status
Needs Triage
labels 2023-07-05 16:10:52 +02:00
Member

Will mark as High prio since this seems to be a recent regression.

Will mark as High prio since this seems to be a recent regression.
Philipp Oeser added
Priority
High
and removed
Priority
Normal
labels 2023-07-06 10:14:46 +02:00
Blender Bot added
Status
Resolved
and removed
Status
Confirmed
labels 2023-07-06 10:15:58 +02:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender-addons#104737
No description provided.