MultiSet
Developer Portal
  • MultiSet Developer Docs
  • Getting Started
    • Changelog
    • VPS SDK : Unity Guide
    • FAQ
  • Basics
    • Maps
      • Mapping Instruction
      • Mapping Planning
      • Mapping Equipment
    • MapSet : Multiple Maps
      • Merging Maps without Overlap
        • Extend a MapSet
      • Merging Maps with Overlap
      • Adjust Map Transformation
    • App Localization
    • Credentials
    • Analytics and Usage
    • Downloads
    • REST API Docs
    • WebXR Integration
    • Third Party Scans
      • Matterport
    • MapFoundry
    • Georeferencing Maps
  • Unity-SDK
    • MultiSet package import
      • Universal 3D (Core) support
    • Sample Scenes
    • On-Cloud Localization
      • Individual Map
      • MapSet (Multiple maps)
        • Hint MapCodes
      • Pose Prior : HintPosition
    • Occlusion
    • NavMesh Navigation
  • Support
  • Native Support
    • iOS Native
Powered by GitBook
On this page
  • Option 1
  • Runtime Occlusion with the existing Mesh
  • Occlusion Behavior in MapSets
  • Option 2
  • 1. Download and Import Raw mesh in Unity
  • 2. Create Occlusion material and texture
  • 3. Apply Occlusion material to the Mesh

Was this helpful?

  1. Unity-SDK

Occlusion

Enable occlusion in your AR apps using the MultiSet Map mesh

PreviousPose Prior : HintPositionNextNavMesh Navigation

Last updated 4 months ago

Was this helpful?

To add occlusion in your AR scene using mesh, follow the below steps

Option 1

Runtime Occlusion with the existing Mesh

The Map Mesh Handler provides runtime management of mesh occlusion through a dedicated "Enable Occlusion" option. This feature optimizes the handling of raw meshes and their occlusion materials during application sessions.

The Map Mesh Handler script performs two primary functions:

  1. Downloads raw meshes as needed during runtime

  2. Applies occlusion materials to these meshes based on session requirements

Occlusion Behavior in MapSets

When working with MapSets, the occlusion system implements a selective application approach:

  • Occlusion is only applied to individual Maps where user localization has occurred

  • This selective application is designed to optimize memory usage throughout the application lifecycle

  • Other Maps within the MapSet remain unaffected until localization is performed

Option 2

1. Download and Import Raw mesh in Unity

From Developer Portal download and import raw mesh, which is low poly and not textured. You can further reduce the size of this mesh in any 3D tool like Blender by reducing the poly count.

2. Create Occlusion material and texture

Create a simple occlusion texture and material that makes mesh invisible in the scene and will provide occlusion in AR if applied to a mesh. Below is a sample of it that you can use

3. Apply Occlusion material to the Mesh

Simply assign the occlusion material to the Mesh and it will become invisible in the editor, alternatively, you can assign this material in runtime using a script.

3KB
PlaneOcclusionShader.shader
2KB
OcclusionMat.mat