Select to view content in your preferred language

Unsupported RenderTexture format error on Android

3401
9
06-14-2022 05:25 PM
yohanbaillot
Emerging Contributor

I am getting errors with the new ArcGIS Map Unity plugin 1.0.0 when compiling to Android on a Mac using Unity 2022.1.x ( on both 2022.1.07a for MagicLeap2 and 2021.1.4f1 latest release from Unity). This is when compiling the ApiSample example coming with the plugin, it is compiling and running but nothing displays and this error seems to be in the library / inaccessible code. Thanks for any help

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.RenderPipelineManager:BeginCameraRendering(ScriptableRenderContext, Camera)

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.RenderPipeline:BeginCameraRendering(ScriptableRenderContext, Camera)

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.Universal.UniversalRenderPipeline:RenderCameraStack(ScriptableRenderContext, Camera)

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.Universal.UniversalRenderPipeline:Render(ScriptableRenderContext, Camera[])

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.RenderPipeline:InternalRender(ScriptableRenderContext, Camera[])

06-14 17:13:21.466 23904 23925 E Unity   : UnityEngine.Rendering.RenderPipelineManager:DoRenderLoop_Internal(RenderPipelineAsset, IntPtr, List`1)

06-14 17:13:21.466 23904 23925 E Unity   : 

06-14 17:13:21.466 23904 23925 E Unity   : [./Runtime/Graphics/RenderTexture.cpp line 877129192]

06-14 17:13:21.466 23904 23925 E Unity   : 

06-14 17:13:21.483 23904 23925 E Unity   : RenderTexture.Create failed: stencil texture format unsupported - R8 UInt (13).

06-14 17:13:21.483 23904 23925 E Unity   : Esri.ArcGISMapsSDK.Renderer.ArcGISTerrainOcclusionRenderer:UpdateTerrainOcclusionDepthTexture(Camera)

06-14 17:13:21.483 23904 23925 E Unity   : Esri.ArcGISMapsSDK.Renderer.ArcGISTerrainOcclusionRenderer:OnBeginCameraRendering(ScriptableRenderContext, Cam

 

 

 

9 Replies
CameronGibbs
Emerging Contributor

@yohanbaillot did you find any solution to this issue? we're seeing the same issue now in our build for android.

0 Kudos
yohanbaillot
Emerging Contributor

No i do not have a solution, i am waiting for ESRI suggestions, i don’t have any 

0 Kudos
Matt_Nelson
Esri Alum

Just to confirm can you try this with Unity 2021? 

0 Kudos
CameronGibbs
Emerging Contributor

CameronGibbs_0-1658362094461.png

Confirming, this is the Unity Version we use.

0 Kudos
Matt_Nelson
Esri Alum

Thanks Cameron. I was going to do some testing on the magic leap soon so I am guessing I will hit this issue hopefully I can find a workaround but I have already opened a bug for it.

Can you try opening the ArcGISRendererComponent.cs file and setting disableTerrainOcclusion to true and seeing if the error persists?

0 Kudos
CameronGibbs
Emerging Contributor

Doing that now, thanks. setting disableTerrainOcclusion to true though because it's already set to False.

Matt_Nelson
Esri Alum

Ah yes that is what I meant. Editing my post to clarify.

0 Kudos
CameronGibbs
Emerging Contributor

setting disableTerrainOcclusion to true means the I get no terrain on Desktop builds. Everything looks fine in Editor but in builds there are no terrain tiles. I have an SLPK added to the map, and that renders fine in the Build still though.

0 Kudos
CameronGibbs
Emerging Contributor

I was able to reproduce the missing terrain in the Editor - after reloading the editor with disableTerrainOcclusion to true. I used the Frame Debugger to figure out that the _ArcGISGlobalTerrainOcclusionDepthMap was defaulting to a gray texture. So I set it to a black texture in ArcGISRendererComponent when 'disableTerrainOcclusion == true'

0 Kudos