Skip to content

Transform types

hn-88 edited this page Apr 27, 2020 · 2 revisions

This page lists what exactly OCVWarp does. It reads a video, transforms it in one of the ways listed below, and writes it back as a video file.

The latest list of transform types is at transformtype.txt.

The transform type parameter in OCVWarp.ini can have the following values.

0 for Equirectangular 360 video to a 360 degree fisheye video

For example, this scene from Paul's 360 youtube video

Source video screenshot

can become something like

Type 0 screenshot

The view angle can be changed with keyboard commands h, u, k, m or with the ini file anglex angley parameters. The above view was with anglex=0.0, angley=-90.0 So, changing anglex to 90.0, we get the following.

Type 0 screenshot with anglex = 90

and so on. This sort of angular fisheye mapping is explained very well on Paul's website.

1 for Equirectangular 360 video to a 180 degree fisheye video

In a 180 degree fisheye video, the field of view is restricted to 180 degrees, or a hemisphere. Only half of the above scene would be visible, like the image below.

Type 1 screenshot

This may be more recognizable as a 180-degree fisheye or fulldome master image if a circle is overlaid over it, like below.

Type 1 screenshot with circle overlaid

2 for 360 degree fisheye to Equirectangular 360

This does the reverse transform of 0. For anglex = angley = 0, a 360 degree fisheye looks like this,

Source video screenshot and after transformtype = 2, this brings back an equirectangular 360 video like this -

Type 2 screenshot

3 for 180 degree fisheye to Equirectangular 360

This does the reverse transform of 1. For anglex = angley = 0, a 180 degree fisheye looks like this,

Source video screenshot and after transformtype = 2, this brings back an equirectangular 360 video like this -

Type 3 screenshot

Here, the bottom half can be recognized as the bottom half of the original 360 scene. Maybe this can be done in a better way :)

4 for 180 degree fisheye (fulldome) to warped file

This does a similar transformation as TGAWarp - this requires a map file similar to the included EP_xyuv_1920.map. The 180 degree fisheye obtained with transform type 1 would become

Type 4 screenshot

5 for Equirectangular 360 video to warped file

This is equivalent to doing a type 1 transformation followed by a type 4 transformation, as above.