Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import TextureAtlas as Mesh is not working properly #35932

Open
nesja opened this issue Feb 5, 2020 · 4 comments
Open

Import TextureAtlas as Mesh is not working properly #35932

nesja opened this issue Feb 5, 2020 · 4 comments

Comments

@nesja
Copy link

nesja commented Feb 5, 2020

Godot version:
3.2 stable

OS/device including version:
Windows10 x64 1809

Issue description:
Not sure that issues are the same: #32869 , #35756
Importing TextureAtlas as mesh gives an incorrect results when used in the Sprite and in the AnimatedSprite. The texture is shifted (1) and some frames are distorted and skipped when animation is playing. AnimationFrame panel looks wrong (2)
atlas

Output:
drivers/gles3/rasterizer_storage_gles3.cpp:3376 - Condition "!(p_format & VisualServer::ARRAY_FORMAT_VERTEX)" is true.

Debugger:
mesh_add_surface: Condition "!(p_format & VisualServer::ARRAY_FORMAT_VERTEX)" is true.

Steps to reproduce:

  • Import TextureAtlas as mesh
  • Use imported textures with Sprite node or AnimatedSprite node as AnimationFrames

Minimal reproduction project:
Launch Scene.tscn and switch between the correct AnimatedSprite_texture node (frames imported as textures) and the AnimatedSprite_atlas_mesh node to see the difference:
atlas.zip

@nesja
Copy link
Author

nesja commented Apr 3, 2020

I can confirm this behavior on Linux. Generated atlas has artifacts

@jesperkondrup
Copy link

jesperkondrup commented Oct 13, 2020

We can also confirm this issue (see image).

Also it looks like the orange gizmo box around the sprite just takes the size of the original image instead of "trimming" the alpha from the image. So if you have an image with a large area of transparent pixels (Like I have in my blue circle sprite) you are probably going to end up with a very large orange box, instead of a nice small cropped gizmo box.

image

@vyshliy
Copy link

vyshliy commented May 18, 2022

Same issue in 3.4.2. The selected Sprite (imported as mesh) should be inside this frame. AnimtedSprite is also broken with this sprites like in issue.

screen

@Calinou
Copy link
Member

Calinou commented May 18, 2022

This is likely not a supported use case within AtlasTexture. See godotengine/godot-proposals#1708 and godotengine/godot-proposals#3530.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants