Is it possible to use spritesheet textures?
See original GitHub issueHello I have a problems with the model textures. If the texture comes from a spritesheet, the model displays the whole spritesheet instead of the proper texture. Here is the code, which I am using. Note that everything works perfectly fine, if I pass a ‘standalone’ texture.
public setTexture(meshIndex: number, texture: Texture) {
let mat = this.model.meshes[meshIndex].material as StandardMaterial;
mat.baseColorTexture = texture;
}
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (3 by maintainers)
Top Results From Across the Web
How to import Textures and Images from a sprite sheet?
We can import Sprites from a sprite sheet using SpritePackedManager. But I could not find any clear-cut way to import Texture or ...
Read more >What is the difference between a sprite sheet and a texture ...
tl;dr : Yes that is absolutely correct. Sprites Sheets often mean a large set of some specific charater's animation frames or multiple ...
Read more >Spritesheets - PixiJS
SpriteSheets help your project in two ways. First, by speeding up the loading process. While downloading a SpriteSheet's texture requires moving the same ......
Read more >Sprites and textures (SFML / Learn / 2.5 Tutorials)
Using as few textures as possible is a good strategy, and the reason is simple: Changing the current texture is an expensive operation...
Read more >TexturePacker - Create Sprite Sheets for your game!
Sometimes it's necessary to use the same sprite multiple times, e.g. in an animation. TexturePacker detects these identical sprites and only adds them...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Added automatic support for spritesheet textures, will come in next release.
Yes, and actually runs very efficient and fast. I left the game loop the animations for 8 hours and the memory usage did not change at all. Is there a better (built-in) way doing this? I did not find something like AnimatedSprite3D, so I had to do it myself by applying tweens.