Skip to main content

Reconstruct3D - 3D Reconstruction

Overview

The Reconstruct3D interface is used to generate 2D and 3D models from aerial triangulation results. It is typically used with ReconstructAT to complete the full reconstruction workflow. This interface supports multiple output formats, block processing, and fine-grained parameter control.

Applicable Scenarios
  • Generate 3D models from aerial triangulation results
  • Generate orthophotos and digital surface models
  • Block reconstruction for large-scale data
  • Need specific output formats

Interface Usage

Command Line Usage

reconstruct_full_engine.exe -reconstruct_type 2 -task_json 3d_config.json

Parameter Description

  • reconstruct_type: Fixed as 2 (indicates Reconstruct3D)
  • task_json: Configuration file path

Configuration Parameters

Required Parameters

ParameterTypeDescription
license_idintSDK license code, unified as 9200
working_dirstringWorking directory (must be same as aerial triangulation)
gdal_folderstringGDAL data path
input_image_typeintImage type: 1=RGB, 2=Multispectral, 3=Infrared
image_meta_dataJSON ArrayInput image metadata information
resolution_levelintReconstruction accuracy: 1=High accuracy, 2=Medium accuracy, 3=Low accuracy

Optional Parameters

Basic Parameters

ParameterTypeDefaultDescription
reconstruct_modeint0Reconstruction mode: 0=General scene, 1=Surrounding scene, 2=Power line scene
min_avali_memory_sizedouble0Minimum available memory (GB), used to control block quantity
fast_modeboolfalseFast mode, improves efficiency but reduces detail
keep_undistort_imagesboolfalseWhether to keep undistorted images

Output Format Control

ParameterTypeDefaultDescription
generate_osgbboolfalseGenerate OSGB format 3D model
generate_3d_tilesboolfalseGenerate 3D Tiles (b3dm) format
generate_lasboolfalseGenerate LAS format point cloud
generate_pc_plyboolfalseGenerate PLY format point cloud
generate_pc_osgbboolfalseGenerate OSGB format point cloud LOD
generate_pc_pntsboolfalseGenerate pnts format point cloud LOD
generate_objboolfalseGenerate OBJ format textured mesh
generate_plyboolfalseGenerate PLY format textured mesh
generate_geotiffboolfalseGenerate GeoTIFF format orthophoto
generate_tile_2DboolfalsePerform tile cutting on orthophoto
generate_2D_from_3D_modelboolfalseGenerate 2D orthophoto from 3D model

Advanced Parameters

ParameterTypeDefaultDescription
use_draco_compressionbooltrueWhether to use Draco compression for 3D Tiles
tex_image_type_3dtilesint03D Tiles texture format: 0=JPEG, 1=WebP
use_gcj02boolfalseWhether to convert orthophoto tiles to GCJ02 coordinate system
coordinate_system_3dJSON-Coordinate system for 3D output
coordinate_system_2dJSON-Coordinate system for 2D output
roi_for_2dJSON-Region of interest for 2D reconstruction
roi_for_3dJSON-Region of interest for 3D reconstruction
roi_coordinate_systemJSONWGS84Coordinate system for ROI

Data Structure Description

Camera Metadata

{
"id": 1, // Unique camera ID
"meta_data": {
"camera_name": "Camera-1", // Camera name
"projection_model": 0, // Projection model (optional)
"width": 4000, // Sensor width (pixels)
"height": 3000, // Sensor height (pixels)
"parameters": [ // Camera intrinsics (10 elements array)
// fx, fy, cx, cy, k1, k2, p1, p2, k3,placeholder_param
]
}
}

ROI (Region of Interest)

{
"boundary": [ // 2D polygon boundary (counter-clockwise)
[x1, y1],
[x2, y2],
[x3, y3]
// ...
],
"min_z": 100.0, // Minimum elevation (optional)
"max_z": 500.0 // Maximum elevation (optional)
}

Output Coordinate System Settings

{
"coordinate_system_3d": {
"type": 3, // Projected coordinate system
"epsg_code": 32650 // UTM Zone 50N
},
"coordinate_system_2d": {
"type": 2, // Geographic coordinate system
"epsg_code": 4326 // WGS84
}
}

Complete Configuration Examples

Basic 3D Reconstruction

{
"license_id": 9200,
"working_dir": "C:/Projects/3D_Task",
"gdal_folder": "C:/MipMap/SDK/data",
"input_image_type": 1,
"resolution_level": 2,
"image_meta_data": [
{
"id": 1,
"path": "C:/Images/DJI_0001.JPG"
},
{
"id": 2,
"path": "C:/Images/DJI_0002.JPG"
}
],
"generate_osgb": true,
"generate_3d_tiles": true,
"generate_las": true,
"generate_geotiff": true
}

High-precision Reconstruction Configuration

{
"license_id": 9200,
"working_dir": "C:/Projects/HighQuality_3D",
"gdal_folder": "C:/MipMap/SDK/data",
"input_image_type": 1,
"resolution_level": 1, // Highest accuracy
"reconstruct_mode": 0, // General scene
"image_meta_data": [...],
"generate_osgb": true,
"generate_3d_tiles": true,
"generate_obj": true,
"generate_geotiff": true,
"generate_tile_2D": true,
"coordinate_system_3d": {
"type": 3,
"epsg_code": 32650 // UTM 50N
},
"coordinate_system_2d": {
"type": 2,
"epsg_code": 4326 // WGS84
}
}

Large-scale Data Block Reconstruction

{
"license_id": 9200,
"working_dir": "C:/Projects/LargeScale_3D",
"gdal_folder": "C:/MipMap/SDK/data",
"input_image_type": 1,
"resolution_level": 2,
"min_avali_memory_size": 16.0, // Limit each block to maximum 16GB memory
"image_meta_data": [...],
"roi_for_3d": {
"boundary": [
[114.12, 22.12],
[114.13, 22.12],
[114.13, 22.13],
[114.12, 22.13]
],
"min_z": 0,
"max_z": 500
},
"generate_3d_tiles": true,
"use_draco_compression": true,
"tex_image_type_3dtiles": 1 // Use WebP texture compression
}

Special Scene Configuration

Surrounding Object Reconstruction

{
"license_id": 9200,
"working_dir": "C:/Projects/Object_3D",
"gdal_folder": "C:/MipMap/SDK/data",
"input_image_type": 1,
"resolution_level": 1,
"reconstruct_mode": 1, // Surrounding scene mode
"image_meta_data": [...],
"generate_obj": true,
"generate_ply": true,
"coordinate_system_3d": {
"type": 1 // Local coordinate system
}
}

Generate Orthophoto Only

{
"license_id": 9200,
"working_dir": "C:/Projects/Ortho_Only",
"gdal_folder": "C:/MipMap/SDK/data",
"input_image_type": 1,
"resolution_level": 2,
"image_meta_data": [...],
"generate_geotiff": true,
"generate_tile_2D": true,
"generate_2D_from_3D_model": true,
"roi_for_2d": {
"boundary": [...] // Specify orthophoto extent
},
"coordinate_system_2d": {
"type": 3,
"epsg_code": 32650
}
}

Output Results

3D Model Output (products/3D/)

  • model-osgb/ - OSGB format model and LOD
  • model-b3dm/ - 3D Tiles format (with tileset.json)
  • model-obj/ - OBJ format model and textures
  • point-las/ - LAS format point cloud
  • point-ply/ - PLY format point cloud
  • point-osgb/ - OSGB format point cloud LOD
  • point-pnts/ - 3D Tiles point cloud format

2D Product Output (products/2D/)

  • geotiffs/ - GeoTIFF format orthophoto and DSM
  • dom_tiles/ - Orthophoto tiles
  • dsm_tiles/ - Digital surface model tiles

Intermediate Results (milestones/)

  • undistorted/ - Undistorted images (if kept)
  • depth_maps/ - Depth maps
  • mesh/ - Intermediate mesh data

Resolution Level Description

LevelDescriptionRelative Processing TimeApplication Scenarios
1Ultra-high accuracy3-5xProfessional surveying, cultural heritage protection
2High accuracy1xGeneral engineering applications
3Quick preview0.2-0.3xQuick validation, preview

Balance Between Accuracy and Efficiency

  • resolution_level=1: Highest geometric detail and texture clarity
  • resolution_level=2: Balance quality and efficiency, recommended for most applications
  • resolution_level=3: Fast processing, suitable for preliminary validation

Best Practices

1. Memory Management

For large-scale data:

{
"min_avali_memory_size": 24.0, // Set based on available memory
"resolution_level": 2 // Consider reducing accuracy
}

2. Output Format Selection

  • Web Display: Use 3D Tiles + Draco compression
  • GIS Analysis: Generate GeoTIFF and LAS
  • Professional Software: Use OSGB format
  • Editing and Processing: Export OBJ or PLY

3. Coordinate System Settings

  • 3D models typically use projected coordinate systems (e.g., UTM)
  • Orthophotos can use geographic or projected systems based on needs
  • Consider using WGS84 for web applications

4. ROI Usage

  • Use ROI generated from aerial triangulation as base
  • Adjust range according to needs
  • Set separate ROIs for 2D and 3D

Performance Optimization

Fast Processing

{
"resolution_level": 3,
"fast_mode": true,
"generate_3d_tiles": true, // Generate only necessary formats
"use_draco_compression": true
}

High-quality Output

{
"resolution_level": 1,
"fast_mode": false,
"keep_undistort_images": true, // Keep intermediate results for inspection
"generate_obj": true, // Generate high-quality mesh
"generate_geotiff": true
}

Common Questions

Q: Error "Cannot find aerial triangulation results"

A: Ensure:

  • working_dir is the same as used in ReconstructAT
  • Aerial triangulation completed successfully
  • milestones directory contains mvs.xml file

Q: Out of memory error

A:

  • Set min_avali_memory_size to limit memory usage
  • Reduce resolution_level
  • Use DivideTiles for pre-blocking

Q: Incorrect output coordinates

A:

  • Check coordinate_system_3d/2d settings
  • Confirm ROI coordinate system matches data
  • Verify GDAL data path is correct

Next Steps


Note: Reconstruct3D provides rich output options. It's recommended to first validate with low accuracy, then proceed with high-quality reconstruction.