Tool for remapping oversampled cube-maps into single images by applying camera intrinsics.
Dependencies:
- cmake
- libpng
- zlib
- OpenGL
- On windows, I suggest using Ninja as the build system.
Clone and fetch submodules:
git clone [email protected]:gareth-cross/cubemap_converter.git
cd cubemap_converter
git submodule update --init --recursive
Configure and build:
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=RelWithDebInfo -Wno-deprecated -Wno-dev -G Ninja
cmake --build .
The suggested way to execute the tool is via the convert_data.py
script:
python scripts/convert_data.py --config <PATH TO TOML> --input <INPUT DATASET DIRECTORY> --output <OUTPUT DATASET DIRECTORY>
Where:
<INPUT DATASET DIRECTORY>
is the directory containing the output of Unreal Engine.<OUTPUT DATASET DIRECTORY>
is the directory in which the converted PNGs will be saved.
This command will:
- Load the calibrations from the TOML file.
- For each camera, generate a remap table from the intrinsics.
- Execute the
cubemap_converter
with the given intrinsic model.
The number of cameras in the dataset directory should match the number of cameras in the TOML file. See the scripts directory for example configurations.