Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

'Error Unity Texture creation failed. 'R32G32B32A32_SFloat' - Amazon Fire tablet

Discussion in 'General Discussion' started by AshTwentyThree, Aug 5, 2022.

  1. AshTwentyThree

    AshTwentyThree

    Joined:
    Jun 17, 2013
    Posts:
    5
    Hey, so I'm getting no 3d graphics when building for the Amazon Fire tablet. It worked about 2 months ago, but now it doesn't. I checked the logs and it gives me this error in every frame:

    'Error Unity Texture creation failed. 'R32G32B32A32_SFloat' is not supported for Render usage on this platform. Use 'SystemInfo.IsFormatSupported' C# API to check format support.'

    I've tried to search for any textures that might use this: 'TextureFormat.RGBAFloat' (I think that's the correct format? I couldn't see the same name as above), but I get no results. I also tried to search for non supported shaders and the 'Hidden/InternalErrorShader' appears in the Editor and Amazon tablet logs, but I can't find what it's attached to.

    I've asked this on Reddit, if people recognise it, but need to ask in here as well, because I'm at an absolute loss.

    Thanks for any help.
     
  2. grizzly

    grizzly

    Joined:
    Dec 5, 2012
    Posts:
    357
    Correct, but it may declared as a RenderTexture. Try
    RenderTextureFormat.ARGBFloat
    and
    GraphicsFormat.R32G32B32A32_SFloat
    if you're going to use
    IsFormatSupported
    .
     
  3. AshTwentyThree

    AshTwentyThree

    Joined:
    Jun 17, 2013
    Posts:
    5
    Hey, thanks for the reply. I was really hoping it was that, but unless I need better code to find the issue, it didn't return anything either.
    I'm using this code to find stuff:
    Code (CSharp):
    1. foreach (var obj in Resources.FindObjectsOfTypeAll(typeof(RenderTexture)) as RenderTexture[])
    2. {
    3.     Debug.Log("resource render texture: " + obj.name);
    4.     if (obj.graphicsFormat == GraphicsFormat.R32G32B32A32_SFloat ||
    5.         obj.format == RenderTextureFormat.ARGBFloat)
    6.     {
    7.         list.Add(obj);
    8.     }
    9. }
    It finds 3 render textures - 'SceneView RT', 'GUIViewHDRRT' and a blank one, but none of them have either of those texture formats.

    This is the full error, if anyone is able to decipher it:

    2022/08/06 11:10:55.130 861 887 Error Unity Texture creation failed. 'R32G32B32A32_SFloat' is not supported for Render usage on this platform. Use 'SystemInfo.IsFormatSupported' C# API to check format support.
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Logger:Log(LogType, Object, Object)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Debug:LogError(Object, Object)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Texture:ValidateFormat(GraphicsFormat, FormatUsage)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.RenderTexture:.ctor(Int32, Int32, Int32, GraphicsFormat, Int32)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.RenderTexture:.ctor(Int32, Int32, Int32, GraphicsFormat)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Rendering.RTHandleSystem:Alloc(Int32, Int32, Int32, DepthBits, GraphicsFormat, FilterMode, TextureWrapMode, TextureDimension, Boolean, Boolean, Boolean, Boolean, Int32, Single, MSAASamples, Boolean, Boolean, RenderTextureMemoryless, VRTextureUsage, String)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Rendering.RTHandles:Alloc(RenderTextureDescriptor&, FilterMode, TextureWrapMode, Boolean, Int32, Single, String)
    2022/08/06 11:10:55.130 861 887 Error Unity UnityEngine.Rendering.Universal.RenderingUtils:ReAllocateIfNeeded(RTHandle&, RenderTextureDescriptor&, FilterMode, TextureWrapMode, Boolean, Int32, Single, String)
    2022/08/06 11:10:55.157 861 887 Error Unity NullReferenceException: Object reference not set to an instance of an object.
    2022/08/06 11:10:55.157 861 887 Error Unity at UnityEngine.Rendering.RTHandleSystem.Alloc (System.Int32 width, System.Int32 height, System.Int32 slices, UnityEngine.Rendering.DepthBits depthBufferBits, UnityEngine.Experimental.Rendering.GraphicsFormat colorFormat, UnityEngine.FilterMode filterMode, UnityEngine.TextureWrapMode wrapMode, UnityEngine.Rendering.TextureDimension dimension, System.Boolean enableRandomWrite, System.Boolean useMipMap, System.Boolean autoGenerateMips, System.Boolean isShadowMap, System.Int32 anisoLevel, System.Single mipMapBias, UnityEngine.Rendering.MSAASamples msaaSamples, System.Boolean bindTextureMS, System.Boolean useDynamicScale, UnityEngine.RenderTextureMemoryless memoryless, UnityEngine.VRTextureUsage vrUsage, System.String name) [0x00000] in <00000000000000000000000000000000>:0
    2022/08/06 11:10:55.157 861 887 Error Unity at UnityEngine.Rendering.RTHandles.Alloc (UnityEngine.RenderTextureDescriptor& descriptor, UnityEngine.FilterMode filterMode, UnityEngine.TextureWrapMode wrapMod
     
    Last edited: Aug 6, 2022
  4. AshTwentyThree

    AshTwentyThree

    Joined:
    Jun 17, 2013
    Posts:
    5
    Well, I managed to fix it and I'm not entirely sure what did it.

    I noticed Screen Space Ambient Occlusion was attached to the Universal Render Data, so I disabled that. Swapped between OpenGles3 and Vulkan (even though I knew Vulkan wouldn't work), enabled 'Allow downloads over HTTP', as I've been getting an editor error with that for ages after a Unity update and looked through any old plugins that were deleted, to see if any remnants of them were left behind.

    I've a feeling it might have been the SSAO, since that could be trying to create a render texture on load.

    Anyway, leaving all this information here, in case it happens to anyone else.