stride3d / stride3d/stride

Repeated glb file updates in resources cause materials to be assigned incorrectly

Open
#3,363 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
C#
Stars
7.8k
Forks
1.2k
Avg merge
2d 17h
Merged PRs (30d)
49

Description

Release Type: Official Release/GitHub (please choose appropriate option)
stride 4.4 beta 5
Version: Version number and/or git branch

Platform(s): Does the problem occur on Windows, Android...?

Describe the bug
A clear and concise description of what the bug is.

After a few edits to a resource glb file it will cause materials to be assigned incorrectly, seems to be related to the number of materials in a file

To Reproduce
Steps to reproduce the behavior:

  1. Using stride 4.4 beta 5 create a fps template project
  2. import \1\v1.glb into the project and drag it into the scene
  3. notice it appears correct
  4. replace the resource file with \2\v1.glb and refresh the scene
  5. notice it appears correct
  6. replace the resource file with \1\v1.glb and refresh the scene
  7. the last cube will have an incorrect material assigned.

Expected behavior
A clear and concise description of what you expected to happen.

I would expect the materials to be assigned correctly

minrepro.zip
Image

Screenshots
If applicable, add screenshots to help explain your problem (use GitHub drag & drop)

Log and callstacks
If any, please attach here any log or callstack (preferably in a .txt file using GitHub drag and drop)

Additional context
Add any other context about the problem here.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by opening the attached minrepro.zip and reproducing the sequence in a Stride 4.4 beta 5 FPS template: import the two v1.glb files, refresh the scene after each replacement, and compare the materials. The work is done when repeated replacements leave every cube with its correct material.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
game-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.