1 Reply
      Latest reply on Sep 12, 2019 3:31 AM by maxxfrazer
      jose_webpac Level 1 Level 1 (0 points)



        When I load a .dae model into my AR app if the object is moved far away (around a meter) then some of the model sufaces start to flicker and mix the color of layers behind. This annoying effect does not happen when the model is close to the camera but persists when you move the device from it.


        I have tried .writesToDepthBuffer, .readsFromDepthBuffer, .renderingOrder properties, SCNLevelOfDetail, etc to try to fix the thing but no luck. The best approach was with readsFromDepthBuffer which reduced flickering but some parts of the model dissapear when camera angle changes so it's not valid solution.


        Some 3D designers say that layers that are very close make this layer fighting but we tried with models with more gap between layers and problem persist. I belive this issue is a AR engine or SceneKit engine bug that does not processes well far objects.


        Any ideas about causes of this problem and possible solutions?


        Best regards

        • Re: AR flickering
          maxxfrazer Level 2 Level 2 (30 points)

          It does sound like Z-fighting, but without a video or even picture it's hard to interpret.


          Assuming that this is what you're seeing, you might want to narrow down your zNear and zFar parameters. The closer these 2 are together the less z-fighting you should have.