Uploaded image for project: 'Minecraft (Bedrock codebase)'
  1. Minecraft (Bedrock codebase)
  2. MCPE-40059

Adding a "varying" variable to a shader pipeline makes it unloadable

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • None
    • 1.8.0
    • None
    • Confirmed
    • Tablet - iOS - iPad Pro
    • 165734

      Not sure if this is a valid issue, but there is a problem in the shader loading code in 1.8.0. This is a regression from 1.7.x.

      When you add a single "varying" variable to a shader pipeline, the game takes an extremely long time, usually several tens of minutes, to load it. The attached resource pack has a customized renderchunk.vertex and renderchunk.fragment whose only change is an extra dummy variable varying vec4 theProblem.

      While the issue doesn't affect the vanilla game play, it severely reduces the potential of custom shaders (because you can have no more communication channels between shader stages). And I suspect this is only a problem came up to the surface whose root cause is something worse.

      Steps to reproduce:

      1. Import the attached addon broken-shader-1.8.0.mcpack.
      2. Enable it in "Global Resources".
      3. Observe that the game freezes for a while.

      I have also attached a diff file to show that the change should be harmless.

            depressed-pho PHO
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: