bevyengine / bevyengine/bevy

copy_texture_to_texture for prepass_depth_texture results in warnings on webgl2

Open
#9,710 0 comments 0 reactions 0 assignees View on GitHub
A-Rendering C-Bug O-WebGL2
Dominant language
Rust
Stars
48.2k
Forks
4.8k
Avg merge
3d 22h
Merged PRs (30d)
161

Description

## Bevy version

807d6465d220015b8eacf4a51071b1165bb9d27f

## What you did

Tried to use the depth prepass with webgl2

## What went wrong

Got these warnings:

Chrome: `[.WebGL-0000002C0AD19500] GL_INVALID_FRAMEBUFFER_OPERATION: Framebuffer is incomplete: Depth stencil texture in color attachment.`

Firefox: `WebGL warning: copyTexSubImage: Framebuffer not complete. (status: 0x8cd6) COLOR_ATTACHMENT0: Attachment's format is missing required color/depth/stencil bits.`

Tested by adding the `DepthPrepass` to the `3d_scene` example.

This narrowed down the issue to this: https://github.com/bevyengine/bevy/blob/807d6465d220015b8eacf4a51071b1165bb9d27f/crates/bevy_core_pipeline/src/prepass/node.rs#L119-L123

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.