Create end-to-end portal in SceneKit

What I'm trying to achieve is to see the "portal" using SceneKit. I have two basic requirements:

  • When moving, the user should be able to see the scene inside the portal from different angles.
  • There must be subtle “2D” levitation in the air portal

My approach is to create a file .daewith a hollow sphere and add two textures to it - transparent on the outer surface and opaque textured inside, so that the user can view the hole and see the internal content. But I try my best to do this, because basically the transparency of the outer texture makes the inner visible. After hours of searching the internet, I still have no answer. How is this functionality achieved?


Portals like this are quite common in different games, so to achieve this, you need to be some kind of basic technique.

+4
source share

Source: https://habr.com/ru/post/1679574/


All Articles