KyryloKuzyk / AR-Foundation-Remote-support

Support page for the 'AR Foundation Remote' plugin on the Asset Store
https://assetstore.unity.com/packages/tools/utilities/ar-foundation-remote-2-0-201106
9 stars 0 forks source link

ArgumentNullException: Value cannot be null #75

Closed iiidefektiii closed 1 year ago

iiidefektiii commented 1 year ago

Describe the bug When using remote it works once then I get "value cannot be null, parameter mesh". Each time I have to close the editor and start it again. Then it works once again and have to go through the same process.

Please provide additional info

  1. Does your existing AR project work fine on a real AR device? Yes
  2. Can your issue be reproduced with plugin examples? To import examples into your project, press the 'Installer/Import Samples' button. YES
  3. Plugin version. You can find it in the 'Packages/AR Foundation Remote/package.json' file. 2.0.30
  4. Unity version and your OS (Windows/macOS/Linux). 2022.3.4f1 LTS
  5. Attach your 'Packages/manifest.json' file to this bug report.
  6. Press 'File/Save' in Unity, then attach your 'Assets/Plugins/ARFoundationRemoteInstaller/Resources/Settings.asset' file to this bug report. it wont allow .asset types so I changed it to Settings.txt
  7. Your AR device model and its OS version. Please make sure your AR device supports ARKit/ARCore and supports a feature you would like to test in the Editor. Pixel 3 (android 12) and Pixel 5 (android 13)

Errors, warnings, and stack traces ArgumentNullException: Value cannot be null. Parameter name: mesh UnityEngine.Rendering.CommandBuffer.DrawMesh (UnityEngine.Mesh mesh, UnityEngine.Matrix4x4 matrix, UnityEngine.Material material, System.Int32 submeshIndex, System.Int32 shaderPass, UnityEngine.MaterialPropertyBlock properties) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.Rendering.CommandBuffer.DrawMesh (UnityEngine.Mesh mesh, UnityEngine.Matrix4x4 matrix, UnityEngine.Material material, System.Int32 submeshIndex, System.Int32 shaderPass) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.Rendering.CommandBuffer.DrawMesh (UnityEngine.Mesh mesh, UnityEngine.Matrix4x4 matrix, UnityEngine.Material material, System.Int32 submeshIndex) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.Rendering.CommandBuffer.DrawMesh (UnityEngine.Mesh mesh, UnityEngine.Matrix4x4 matrix, UnityEngine.Material material) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.XR.ARFoundation.ARBackgroundRendererFeature+ARCameraBackgroundRenderPass.Execute (UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Rendering.Universal.RenderingData& renderingData) (at ./Library/PackageCache/com.unity.xr.arfoundation@5.0.6/Runtime/ARFoundation/ARBackgroundRendererFeature.cs:162) UnityEngine.Rendering.Universal.ScriptableRenderer.ExecuteRenderPass (UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Rendering.Universal.ScriptableRenderPass renderPass, UnityEngine.Rendering.Universal.RenderingData& renderingData) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/ScriptableRenderer.cs:1490) UnityEngine.Rendering.Universal.ScriptableRenderer.ExecuteBlock (System.Int32 blockIndex, UnityEngine.Rendering.Universal.ScriptableRenderer+RenderBlocks& renderBlocks, UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Rendering.Universal.RenderingData& renderingData, System.Boolean submit) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/ScriptableRenderer.cs:1446) UnityEngine.Rendering.Universal.ScriptableRenderer.Execute (UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Rendering.Universal.RenderingData& renderingData) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/ScriptableRenderer.cs:1222) UnityEngine.Rendering.Universal.UniversalRenderPipeline.RenderSingleCamera (UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Rendering.Universal.CameraData& cameraData, System.Boolean anyPostProcessingEnabled) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/UniversalRenderPipeline.cs:650) UnityEngine.Rendering.Universal.UniversalRenderPipeline.RenderCameraStack (UnityEngine.Rendering.ScriptableRenderContext context, UnityEngine.Camera baseCamera) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/UniversalRenderPipeline.cs:816) UnityEngine.Rendering.Universal.UniversalRenderPipeline.Render (UnityEngine.Rendering.ScriptableRenderContext renderContext, System.Collections.Generic.List1[T] cameras) (at ./Library/PackageCache/com.unity.render-pipelines.universal@14.0.8/Runtime/UniversalRenderPipeline.cs:362) UnityEngine.Rendering.RenderPipeline.InternalRender (UnityEngine.Rendering.ScriptableRenderContext context, System.Collections.Generic.List1[T] cameras) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.Rendering.RenderPipelineManager.DoRenderLoop_Internal (UnityEngine.Rendering.RenderPipelineAsset pipe, System.IntPtr loopPtr, UnityEngine.Object renderRequest, Unity.Collections.LowLevel.Unsafe.AtomicSafetyHandle safety) (at <17484a9af6b944dea5cd9be4dbb0da2c>:0) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&) Settings.txt

iiidefektiii commented 1 year ago

I just updated to the latest version on the store (2.0.31-release.1) and still getting the same error. Error also occurs in the sample scenes. Any known fix for this?

iiidefektiii commented 1 year ago

I did try in a completely new project and does not happen in the new project. Not sure what would've changed in my project to cause the error but it no longer works and I am so far a long I cannot just move everything to a new project.

iiidefektiii commented 1 year ago

I think I found the issue causing the error. Not sure why but the setting in Player Settings -> Editor -> Enter Play Mode Options ->Enable Play Mode Options I enabled this after seeing someone say it helps with unity constantly repainting and loading the domain. When I deleted the Library it re imported and that setting turned back off. When I turned it back on the error came back and turning back off it went away again. Capture

iiidefektiii commented 1 year ago

See last comment. Not an ARFoundation Remote issue but contributes to it not working properly in the editor.