Alpha Channel Masks

Imagine you want to mask/hide some parts of your images, like windows, water, sky, shadows, vegetation, or noise, so that they will not be used in the reconstruction. Masks can also help the reconstruction when you need to turn the scanned object on its side, upside down or just around to capture all details in a more convenient way. You can create alpha masks in an external image editing software and bring the masked images into RealityCapture (RC) or generate and export them automatically directly through this application.

NOTE: Using masks with RealityCapture is not necessary but can improve the results and speed up the process when all else fails, so its use is rather specific to your particular case. Using masks may help you to filter-out unwanted geometry during the reconstruction phase and hence simplify further model cleaning, e.g., by using lasso and other filtering tools.

Masks represent a non-destructive way of editing images. They may be separate (png) images or the information on your selection can be added to the originals (saved as tiffs). They are stored in alpha channels and come as grayscale images.
Areas painted black are unmasked, the white areas are masked. You can possibly use up to 256 shades of grey in an alpha channel. However, for purposes of use in RC, we do not recommend you to use any level of transparency in the masked areas of images and apply any filter in the images, since it could confuse its algorithms during processing. The alpha channels are specifically used during feature detection and meshing.

How to Display the Mask

You can check the masks directly in RC. This is how you do that:

  1. Drag an image into the 2D view.
  2. Go to the Image 2D/VIEW tab.
  3. Click the Mask button in the Source part of the tab and you should see masked image in the 2D view.

NOTE: As for the above-mentioned procedure, when an image does not contain a mask, nothing will be displayed (and no mask can be used in the reconstruction).

To display an image back, click the Geometry button in the Source part of the Image 2D/VIEW tab.

You can also select between the imported layers in the Source panel by pressing the TAB key on the keyboard.

Export Texture Alpha

When exporting a mesh in obj, fbx, dxf, dae, bvh, htr, trc, asf, amc, c3d, aoa, or mcd formats, you can find Export texture alpha in the Texturing settings of the Export Model window, and set it to True in order to export the mask.


Export of Masking Image Layers

Masks can be generated and exported automatically through the Depth and Mask button in the Export part of the MESH MODEL tab or the SCENE 3D/TOOLS tab.
Depth maps (defining a distance between the camera and the surface that it is looking at) define which part of the inserted object is visible. They are created from a rendered reconstructed mesh used for automatic fitting the object into the image. Their output format is .exr for depth layers and .png. for masks.

In the 'Export Depth Maps and Masks' dialog window, you can define separately whether you want to export mesh masks and/or camera depths maps. For explanation of the undistortion settings in the export dialog, please navigate to Undistorted Images.


Import of RC Masking Image Layers

Masks can be imported back to RealityCapture by Drag & dropping them back to RealityCapture after exporting them to the same folder as original inputs are located.


How to use Masking layer

When using masks, you can choose if you: