-
Hi, I have a spritesheet with large sprites (256x384). I want to render these sprites to the screen as a smaller size (e.g. 64x96). I have written a function to create the bundles:
} I can adjust the size by using the Scale, but was wondering if there is a way to do it like I can with my normal sprite creation function:
} I hope my question makes sense. Thanks. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
I want to change the bundle for
Both cases will be bundled with |
Beta Was this translation helpful? Give feedback.
I want to change the bundle for
TextureAtlas
es a bit once the renderer rework lands on main. If aSprite
is constructed with a Texture its bundle containsSprite
,Handle<Image>
etc. If it's constructed from aTextureAtlas
-Texture its bundle containsTextureAtlasSprite
,Handle<TextureAtlas>
etc. I want to unify this. The Sprite Texture will be represented by:Handle<Image>
,TextureAtlas
:Handle<TextureAtlas>
+TextureAtlasEntry
,Both cases will be bundled with
Sprite
. So no moreTextureAtlasSprite
and unified functionality.Then, you can use the
custom_size
property ofSprite
for both cases. Feel free to create an Issue for this.