Transparent materials appear black or opaque after runtime import on Meta Quest.

Ouverte
#809 7 commentaires 0 réactions 1 personne assignée Voir sur GitHub

@robertdorn83 y travaille déjà.

Depuis le 13/2/2025.

Évaluation

Cette issue n'a pas encore été évaluée.

Description

bug
Describe the bug 💬

When placing the GLB model in the Unity scene before building the app, all transparent materials (e.g., glass and EyeAO) render correctly. However, after building the app and loading the model at runtime using the GLTFComponent, all surfaces with transparent materials are rendered as black or opaque instead of transparent.

Image

Image

On the left (black eyes), you can see the model that has been instantiated, and on the right, the model that was already in the scene.
Image

Steps to reproduce 🔢
  1. Open Unity and place the GLB model directly into the scene. (this will work fine)
  2. Ensure the transparent materials (e.g., glass of the glasses, EyeAO) are displayed correctly in the editor.
  3. Add a EmptyGO with a GLTFComponent attached to it. This is what will instantiate the avatarToTest.glb at run time .
  4. Add the avatarToTest.glb to a streaming assets folder in the project and reference it in the GLTFComponent .
  5. Build and run the application.
  6. At runtime, use the GLTFComponent to load the same GLB model into the scene.
  7. Observe the model’s materials: all surfaces with transparent materials are rendered as black or opaque instead of transparent.
Files to reproduce the issue ♻

avatarToTest.zip

Editor Version 🎲

2022.3

Render Pipeline and version

URP

UnityGLTF Version

2.14.1

Operating System 👩‍💻

Android

When does this problem happen?
  • Editor Import
  • Runtime Import
  • Editor Export
  • Runtime Export
Additional Info 📜

No response

Validations 🩹
Langage dominant
C#
Étoiles
2.3k
Forks
539
Merge moyen
3 j 15 h
PR mergées (30 j)
2

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de KhronosGroup/UnityGLTF

Toutes les issues de KhronosGroup/UnityGLTF

Issues similaires

Plus d'issues C#

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.