Seeking advice on an implementation approach from the PolySpatial team

Hi there,

We have a game that we’re porting to visionOS as a mixed reality experience, but we have a need for it to take part in a custom clipped volume, so that we can have a full room experience, with a kind of “virtual 3D TV” (it would be actual 3D though, some depth, so not flat in any kind of render to texture way), where objects can spawn from it into the room. It needs hand tracking and full room scanning. This means the app itself would be unbounded, but we ourselves want to maintain a custom bounded volume from within it.

We’re currently not sure how to implement this with PolySpatial. I cannot see the ability to do the equivalent of “discard_fragment” to do custom clipping (one approach we had for doing custom clipping), and it would appear as though PortalComponent in RealityKit is not something available to us in PolySpatial. Rendering our game in a portal was an alternate approach we were interested in.

Do you have any advice as to how we’d create custom clipped volume within the application volume? Is there currently a method to be able to implement custom RealityKit components in such a way that integrates with the PolySpatial runtime?

Thanks in advance,

-Jack.

While there’s no equivalent to “discard fragment,” In shader graphs, you can use alpha clipping or transparency to achieve this effect. Note that alpha clipping currently requires the “Transparent” output mode (alpha clipping overrides blending on visionOS anyway).

We are currently working on support for stereo render targets, which would allow you to achieve this effect by using Unity to render to a pair of textures (one for each eye). However, others have requested support for PortalComponent, so we may reconsider adding support for it in the future.

Unfortunately, no.

OK, well it would appear as though we need PortalComponent for our game (a port) to be possible. It is a launch title with Apple, and so this marks a critical blocker for us.

Please consider adding support for PortalComponent, or try to find a mechanism that would allow us to add support ourselves while playing nice with PolySpatial.

Cheers,

-Jack.

OK; I will bring this up again with the team.