feat: export cubemap recordings as equirectangular videos - #93
Open
chaiyuntian wants to merge 2 commits into
Open
chaiyuntian wants to merge 2 commits into
chaiyuntian wants to merge 2 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add export of six synchronized cubemap views to a full 360-by-180-degree, 2:1 equirectangular (ERP) MP4, addressing the panoramic recording export requested in #85.
CubemapProjectorreuses projection maps andsave_panorama_videoconsumes frames incrementally instead of retaining the recording in memory. Inputs use six documented Unreal camera orientations and BGR uint8 arrays. Invalid dimensions, incompatible faces, empty recordings and writer failures are reported explicitly, and the encoder is released if capture or projection fails. This uses the existing NumPy/OpenCV dependencies.The sensor guide includes the face convention and a runnable example that exports recorded PNG sequences. A single perspective video cannot supply the missing views. Capture must supply synchronized faces; this PR implements the export stage and does not add UE capture commands or spherical-player metadata.
Fixes #85.
Validation evidence
31 tests pass on each of Python 3.10 and 3.12 on Windows, including:
Reproduce from the repository root:
The CI workflow tests Windows/Linux and Python 3.10/3.12, and uploads JUnit reports plus
synthetic-erp-reference.pngandsynthetic-erp.mp4. These are explicitly synthetic projection/encoding evidence, not recordings from a running SimWorld UE server.Remote CI passed on all four combinations for the current PR head
540bdad7078abe68a51c9bf79af95e8f112d96c2: workflow results and downloadable evidence. Each job runs all 31 tests. Download the Linux/Python 3.10 JUnit report, ERP PNG and MP4 sample.The repository's pre-commit checks pass for changed files (flake8 was limited to one worker locally). Sphinx HTML builds successfully; rendered guide and API entries were checked. Its three existing upstream broken-reference warnings are unchanged, with no new warnings or errors.