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

Vulkan Mobile: Clip Children shows a copy of all nodes in the scene #75956

Closed
Tracked by #55871
Insane-Owl opened this issue Apr 12, 2023 · 7 comments · Fixed by #90821
Closed
Tracked by #55871

Vulkan Mobile: Clip Children shows a copy of all nodes in the scene #75956

Insane-Owl opened this issue Apr 12, 2023 · 7 comments · Fixed by #90821

Comments

@Insane-Owl
Copy link

Insane-Owl commented Apr 12, 2023


Bugsquad note: This issue has been confirmed several times already. No need to confirm it further.


Godot version

4.0.2.stable

System information

Windows 11, AMD RX 6700 XT (23.4.1), Mobile renderer

Issue description

sprites with clip_children - 'Clip Only' enabled, have a shrunk-down mirror of the scene behind them.

This only happens in the Mobile renderer

Godot_4_cYreMgGK0z
Godot_4_rOcYBV4uRd

Steps to reproduce

  1. Create a background, e.g. a sprite
  2. Add a sprite with clip_children enabled
  3. Add another sprite as a child of the one with clip_children enabled, and scale it down or turn down its transparency
  4. The background sprite will appear behind it (may require moving it)

Minimal reproduction project

Clip Children Bug.zip

@clayjohn
Copy link
Member

For some reason the entire background is copied into a rect the size of the Parent.

The issue is likely comes from here:

if (RendererSceneRenderRD::get_singleton()->_render_buffers_can_be_storage()) {
copy_effects->copy_to_rect(rt->color, rt->backbuffer_mipmap0, region, false, false, false, true, true);
} else {
copy_effects->copy_to_fb_rect(rt->color, rt->backbuffer_fb, region, false, false, false, false, RID(), false, true);
}

@Calinou Calinou changed the title Clip Children shows a copy of all nodes in the scene | Mobile Renderer ONLY Vulkan Mobile: Clip Children shows a copy of all nodes in the scene Apr 12, 2023
@AndyAstrand
Copy link

I can also report this is happening for me in the editor, and in the emulator, and on Android using gl_compatibility mode.
https://youtu.be/usgMUOv_7EI

@Insane-Owl
Copy link
Author

Can confirm problem still exists in Godot 4.1.stable

@endritdev1
Copy link

Still happening :/

@vyshliy
Copy link

vyshliy commented Nov 29, 2023

Confirmed in 4.2 rc2

@denq04
Copy link

denq04 commented Dec 12, 2023

Confirmed in v4.2.stable.mono.official [46dc277]

@htmiel
Copy link

htmiel commented Apr 16, 2024

Any news on this? I'm trying to use a Polygon2D as a mask with Clip Children, and I have the same behavior on the Mobile renderer. (Godot 4.2.1 / Win10)

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

Successfully merging a pull request may close this issue.

7 participants