mojira.dev
MC-276717

The game generates unusable depth textures for post render targets

Each internal render target created by the game for post chains has a depth texture, but depth testing is disabled before these shaders get executed, making them unusable.

In previous versions (1.20.1 and before) depth testing wasn't disabled, so writing to depth textures was possible. Attached is a resource pack that tries to write 0.5 to the depth texture with gl_FragDepth and then displays the contents of it to the screen, getting 1.0.

Steps to Reproduce:

  1. Attach render-doc to the game (for simplicity)

  2. Load in the resource pack attached to the issue and create a frame capture

  3. Find the draw call that renders the "test.json" pass from the resource pack (it renders a magenta image, which should be easily visible in the texture viewer)
    → For me this is right before a debug name called "Color Pass #4"

  4. Check the frame-buffer (FB) on the pipeline state page.-

Observed Results:

As seen on the image below, the frame-buffer has two attachments, a color texture and a depth texture.

[media]


But checking the depth state below this point shows that writing to it is disabled

[media]

Expected Results:

Either keep the original (pre 1.21.2) functionality and enable depth testing to let post shaders write to the depth buffer or disable depth buffer creation for these targets, as they are redundant.

Attachments

Comments 5

We do not have enough information to reproduce this issue.

Please include the following information to help us understand your problem:

Steps to Reproduce:
1. (Explain what needs to be done for the issue to happen)
2.
3.

Observed Results:
(Briefly describe what happens)

Expected Results:
(Briefly describe what should happen)

Please also attach any needed commands, add-ons/behavior packs, data packs, resource packs, screenshots, videos, or worlds needed to help reproduce this issue.

Refer to the Bug Tracker Guidelines for more information about how to write helpful bug reports. Bug reports with insufficient information may be closed as Incomplete.

This issue is being temporarily resolved as Awaiting Response. Once the requested information has been delivered, the report will be reopened automatically.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki

Steps to Reproduce:

  1. Attach renderdoc to the game (for simplicity)

  2. Load in the resourcepack attached to the issue and create a frame capture

  3. Find the drawcall that renders the "test.json" pass from the resourcepack (it renders a magenta image, which should be easily visible in the texture viewer)

    1. For me this is right before a debug name called "Colour Pass #4"

  4. Check the framebuffer (FB) on the pipeline state page.-

Observed Results:

As seen on the image below, the framebuffer has two attachments, a color texture and a depth texture.

[media]

But checking the depth state below this point shows that writing to it is disabled

[media]

Expected Results:
Either keep the original (pre 1.21.2) functionality and enable depth testing to let post shaders write to the depth buffer or disable depth buffer creation for these targets, as they are redundant.

How does this affect the gameplay? This ticket will automatically reopen when you reply.

The depth buffers use up extra VRAM and the clearing of them wastes GPU resources without providing any benefits

Thank you for your report!
After consideration, the issue is being closed as Invalid.

You have posted a feature request or a suggestion. This site is for bug reports only.
For suggestions, please visit The official Minecraft feedback site or visit the Minecraft Feedback Discord server.

Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support (Technical Issues) – 📧 Microsoft Support (Account Issues)
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki

BalintCsala

(Unassigned)

Plausible

Performance, Rendering, Resource Packs

24w37a

Retrieved