Search Unity

Metal: GrabIntoRenderTexture mismatched grab pass

Discussion in 'Global Illumination' started by sharkapps, May 24, 2017.

  1. sharkapps

    sharkapps

    Joined:
    Apr 4, 2016
    Posts:
    145
    I am receiving over a dozen of these error messages in the Console when baking lighting in Unity 5.6.1f1.

    Metal: GrabIntoRenderTexture mismatched grab pass: 81 / 115

    There is no other information in the console. What is this error and what is the impact? I am building an app for Metal and the lighting seems dark, but I can't tell if this error is related or not.
     
    Enrico-Monese and effx like this.
  2. gopietz

    gopietz

    Joined:
    Jun 5, 2017
    Posts:
    1
    im having the same exact problem. even "81 / 115" is identical. any news on this?
     
  3. Gizmoi

    Gizmoi

    Joined:
    Jan 9, 2013
    Posts:
    327
    Me too.
    Code (CSharp):
    1. Metal: GrabIntoRenderTexture mismatched grab pass: 81 / 115
     
    Last edited: Jun 20, 2017
  4. effx

    effx

    Joined:
    Aug 24, 2015
    Posts:
    6
    I figured out that my issue was having the experimental Metal Editor option enabled in the Player Settings. You need to disable Metal Editor setting.

    I had to do a round about way in fixing avoiding the issue since I could not open my Unity project on my Mac to disable this option. I had to first remove all my assets that were causing the editor from opening. I found out which files were causing the issue by checking what files were loading in the log right before the error.

    After removing the files, I opened Unity, disabled the Metal Editor setting and added my files back and was able to continue from there.

    As of now I do not know of any way to change the Player Settings outside of Unity so this might be your only work around.
     
  5. Gizmoi

    Gizmoi

    Joined:
    Jan 9, 2013
    Posts:
    327
    If you look at the "Project Settings/ProjectSettings.asset" file, and find the line that says "metalEditorSupport: 1", you can change that to "metalEditorSupport: 0" and this should be disabled when you reopen Unity.

    Unfortunately I need the Metal support enabled as I am using Compute Shaders.

    EDIT: In Unity 2017b10 I don't get the error any more but the RenderTexture I assigned to a shader is appearing all black.

    EDIT EDIT: nvm I just had to add the 'metal' flag to my shader.
    Seems to be fixed in Unity 2017.
     
    Last edited: Jun 26, 2017
  6. effx

    effx

    Joined:
    Aug 24, 2015
    Posts:
    6
    Thanks for the tip

    Good to hear it's fixed in 2017
     
  7. DragonDust

    DragonDust

    Joined:
    May 11, 2016
    Posts:
    2
    Me too. Unity version 2017.1.1f1.
    "Assertion failed: Metal: GrabIntoRenderTexture mismatched grab pass: 115 / 80"
     
  8. madGlory

    madGlory

    Joined:
    Jan 12, 2016
    Posts:
    44
    Hey Gizmoi,

    I'm having a similar issue, would you mind posting the "metal" flag? I don't quite know where to find it.

    Thanks!
     
  9. kristijonas_unity

    kristijonas_unity

    Unity Technologies

    Joined:
    Feb 8, 2018
    Posts:
    1,080
    Please upgrade to newer Unity versions, if possible. If the bug reproduces in currently supported LTS, or Tech Stream versions (2019.4, 2020.3, and 2021.1), please submit a bug report.
     
  10. WookieWookie

    WookieWookie

    Joined:
    Mar 10, 2014
    Posts:
    35
    Still happening in Unity 2021.2.5f1, I'm sure plenty of people submitted bug reports.
     
  11. giorgos_unity

    giorgos_unity

    Unity Technologies

    Joined:
    Nov 14, 2019
    Posts:
    38
  12. jbooth

    jbooth

    Joined:
    Jan 6, 2014
    Posts:
    5,461
    I'm seeing this in 2021.3, but am not using GrabPass in any of my shaders or code. It seems to come and go, but once it happens, it's a constant stream of errors.