Correcting terrestrial laser scan registration for use in RealityScan - Introduction
Correcting terrestrial laser scan registration for use in RealityScan - Introduction
Author: Stefan Lindgren and Carolina Larsson - Last update 2026-08-19
Citation:
Larsson, C., & Lindgren, S. (2026). Open-Source Workflow for Correcting Terrestrial Laser Scan Registration for RealityScan [Computer software]. Zenodo. doi.org/10.5281/zenodo.21989989
Introduction
This documentation describes a workflow for correcting registration errors in terrestrial laser scan projects while preserving compatibility with RealityScan.
RealityScan expects each terrestrial scan to remain in its original scanner-centered coordinate system while the scan registration is stored separately as a transformation matrix. When PTX files are imported into software such as MeshLab, this transformation is automatically applied to the scan geometry. Although the scans may appear correctly positioned, the original relationship between scanner coordinates and transformation matrices is lost, making the modified files unsuitable for direct use in RealityScan.
The workflow solves this problem by creating working files for alignment and registration correction while preserving the original PTX files. Registration errors can then be corrected using MeshLab and Blender, after which the updated transformations are transferred back to the original PTX files.
Although the examples use scans acquired with a Faro Focus scanner and exported from Faro Scene, the workflow is not limited to Faro equipment. The same principles can be applied to other terrestrial laser scanners and registration software that support export of scan data together with transformation information.
Purpose
The purpose of this workflow is to:
• Correct registration errors outside the original registration software.
• Preserve the relationship between scanner coordinates and transformation matrices.
• Maintain compatibility with RealityScan.
• Enable Blender to be used as a registration correction tool for terrestrial laser scan projects.
When Is This Workflow Useful?
This workflow is intended for situations where:
• A terrestrial laser scan project contains registration errors.
• The original registration software does not provide satisfactory correction tools.
• Additional manual adjustment is required.
• The corrected scans must remain compatible with RealityScan.
If the scans are already correctly registered, it is normally sufficient to export them directly from the registration software and import them into RealityScan.
Workflow Overview
The workflow consists of five main stages:
1. Export scans from the registration software.
2. Create working files for registration correction.
3. Recreate the original registration in MeshLab.
4. Correct registration errors using MeshLab and Blender.
5. Transfer the corrected transformations back to the original scan files and import them into RealityScan.
Registration software
↓
PTX
↓
PTX_to_PLY_and_MLP.py
↓
PLY + MLP
↓
MeshLab
↓
Blender-assisted
registration correction
↓
Corrected MLP
↓
ChangePTXmatrixFromMLP.py
↓
Corrected PTX
↓
RealityScan
Software used
The workflow uses the following software:
Software | Purpose |
|---|---|
Registration software (e.g. Faro Scene) | Export scan data |
Python | Run automation scripts |
PyMeshLab | Create working files and process scan data |
MeshLab | Recreate and refine scan registration |
Blender | Manual registration correction |
RealityScan | Final processing and model generation |
Why Python and PyMeshLab Are Used
Terrestrial laser scan projects often contain many scans. While the workflow can be performed manually, several operations would then need to be repeated for every individual scan file.
To save time and reduce the risk of errors, the workflow uses a small number of Python scripts based on PyMeshLab. These scripts automate repetitive tasks such as creating working files and transferring transformation information between different software.
No programming experience is required. The scripts are provided ready to run and are used as part of the workflow described in this documentation.
Workflow scripts
The workflow uses a small number of scripts to automate repetitive tasks and transfer transformation information between different software packages.
PTX_to_PLY_and_MLP.py
Creates working files from PTX scans.
Input: PTX files
Output: PLY files and MLP files
The script preserves the transformation information stored in the PTX files while creating lightweight files suitable for alignment work.
Meshlab_Blender_scripts.blend
A Blender file with a number of Blender python scripts for registration correction.
Included scripts:
• 1_ImportFromMLP.py
• 2_moveObToPos.py
• 3_PointCloud.py
• 4_exportMLP.py
Together these scripts make it possible to import scan positions from MeshLab, perform registration corrections in Blender and export updated transformations back to MeshLab.
ChangePTXmatrixFromMLP.py
Transfers corrected transformations from a MeshLab project back to the original PTX files.
Input: Corrected MLP file and Original PTX files
Output: Corrected PTX files
This step restores RealityScan compatibility after the registration has been corrected.
Documentation Structure
The workflow is documented as a series of tutorials.
Tutorial 1: Installing Python and PyMeshLab
Installs the software required to run the automation scripts.
Output:
• Working Python installation
• Working PyMeshLab installation
Tutorial 2: Exporting and preparing PTX files for registration correction
Exports scans and creates the working files used throughout the workflow.
Input: PTX files
Output: PLY files and MLP files
Tutorial 3: Recreating and testing the registration in MeshLab
Builds a MeshLab project that reproduces the original scan registration.
Input: PLY files and MLP files
Output: MeshLab registration project
Tutorial 4: Blender assisted registration correction
Uses Blender to perform registration correction and manual adjustment.
Input:
• MeshLab registration project
• PLY files
• MLP files
Output:
• Corrected MLP file
Tutorial 5: Updating PTX files and importing into RealityScan
Transfers corrected transformations back to the original PTX files and imports them into RealityScan.
Input: Corrected MLP file and Original PTX files
Output: Corrected PTX files and RealityScan project
Reference Documents
The following reference documents provide additional technical background for users who want a deeper understanding of how the workflow operates internally.
Understanding PTX, MeshLab and Transformation Matrices
Explains how scanner coordinates, transformation matrices and registration information are represented in PTX files, MeshLab project files (MLP) and related software.
Topics include:
• Scanner coordinates and transformations
• PTX file structure
• MeshLab project files (MLP)
• Transformation matrix representations
• RealityScan compatibility requirements
How PTX_to_PLY_and_MLP.py Works
Explains the manual workflow automated by the script PTX_to_PLY_and_MLP.py.
Topics include:
• Point cloud subsampling
• Creating PLY working files
• Creating MLP project files
• Transferring transformation matrices
• Matrix inversion
• Separation of point cloud data and transformation information
Recommended Reading Order
For most users:
1. Install Python and PyMeshLab
2. Prepare PTX scans
3. Recreate the registration in MeshLab
4. Correct the registration in Blender
5. Update PTX files and import them into RealityScan
The reference documents can be consulted whenever additional technical background is needed.

