Skip to content

Commit

Permalink
fix(texture): flag newly created textures for upload
Browse files Browse the repository at this point in the history
  • Loading branch information
fallenoak committed Dec 28, 2023
1 parent 02fc2c3 commit 4b34a05
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/lib/TextureManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,9 @@ class TextureManager {
texture.name = normalizePath(path).split('/').at(-1);
texture.userData.cacheKey = cacheKey;

// All newly loaded textures need to be flagged for upload to the GPU
texture.needsUpdate = true;

this.#loaded.set(cacheKey, texture);
this.#loading.delete(cacheKey);

Expand Down

0 comments on commit 4b34a05

Please sign in to comment.