<p>I would be tempted to use a solution which involves decoding a single rectangular video stream so you don't need any special video decoder. As you have said there will be performance penalties for decoding multiple seperate streams. </p>

<p>Something like octohedran cube maps might be a good offline way to convert 6 video streams into a single video stream while minimizing distortion. A relatively cheap pixel shader can be used to project the 'cube' map back to camera space.</p>

<p>Further reading here > <a href="http://www.vis.uni-stuttgart.de/~engelhts/paper/vmvOctaMaps.pdf" rel="nofollow noreferrer">http://www.vis.uni-stuttgart.de/~engelhts/paper/vmvOctaMaps.pdf</a></p>

CC BY-SA 3.0
2017-07-28T17:11:07.130Z
Non-pyramid view frustum is not supported by rasterisators, but we use ray-tracer and it may have sense in our case. Also pixel density can be adjusted to be one-to-one on resulting flat video, but still pixel density is not uniform in case of octamap.
Tomilov Anatoliy
CC BY-SA 3.0
2017-07-28T17:17:19.707Z
Currently "3x2-unfolded" video is used. The video looks seamless. No edges, no distortion on the first (and second) glance. Only four edges are glued and ten are onto the outer boundary. Currently used codec is randomly chosen and it is a luck, that there is no notable seams. (OpenGL supported) cubemap is a way to avoid geometry and filtering on glued and outer edges at all. It is interesting to try octamap, but presumably it have more distortion on the one hand and less glued and outer edges OTOH. Pixel to pixel mapping is impossible in case of non-cube Platonic solids.
Tomilov Anatoliy
CC BY-SA 3.0
2017-07-28T14:21:24.263Z
2017-07-28T14:27:02.617Z
2017-07-28T14:27:02.617Z
PaulHK
<p>What is the best way to save video from faces of a cube? The render can produce 6 squares (90°x90°) of 1024x1024 resolution. Faces oriented along axies and only position is changed continuously. I want to save them into the video stream and then play back them into 360° panorama viewver by means of projection on the cube or using cubemap (OpenGL ES).</p>

<p>What is the best codec suitable and what is the best way to save video for above purposes? Is it better to use six separate synchronized video streams or, instead, to enclose all six faces into the one?</p>

<p>If cube is unfolded into six square bitmaps and composed into a 3x2 (or 2x3) rectangle, then it is possible to get artifacts on glued inner edges and on the outer edge of the resulting rectangle. I sure it may depend on codec used to compress/decompress resulting video.</p>

<p>In case of 6 separate video streams it is possible to render only 5 of 6 (or 3 of 6 in case of only pitch and yaw (but not roll) rotations are possible) faces of cube, i.e. only visible ones. But on the other hand it may be waste of resources to support six separate streams due to necessity of attendant metainformation handling.</p>

<p>What are expected performance issues inherent to different approaches?</p>

<p>The relevant platform is average home desktop PC.</p>

CC BY-SA 3.0
2017-07-28T13:40:33.397Z
There is a lack of `360 panorama`, `cubemap` (!), `codec` and other relevant tags on computergraphics.stackexchange.com.
Tomilov Anatoliy
CC BY-SA 3.0
2017-07-28T14:43:01.220Z
If you do not use the mobile interface then you can make new tags if you wish.
joojaa
<opengl><rendering><projections><video>
A way to save 360° panorama video
Tomilov Anatoliy
# A way to save 360° panorama video

(Asked by: username_0 on 2017-07-28)

What is the best way to save video from faces of a cube? The render can produce 6 squares (90°x90°) of 1024x1024 resolution. Faces oriented along axies and only position is changed continuously. I want to save them into the video stream and then play back them into 360° panorama viewver by means of projection on the cube or using cubemap (OpenGL ES).

What is the best codec suitable and what is the best way to save video for above purposes? Is it better to use six separate synchronized video streams or, instead, to enclose all six faces into the one?

If cube is unfolded into six square bitmaps and composed into a 3x2 (or 2x3) rectangle, then it is possible to get artifacts on glued inner edges and on the outer edge of the resulting rectangle. I sure it may depend on codec used to compress/decompress resulting video.

In case of 6 separate video streams it is possible to render only 5 of 6 (or 3 of 6 in case of only pitch and yaw (but not roll) rotations are possible) faces of cube, i.e. only visible ones. But on the other hand it may be waste of resources to support six separate streams due to necessity of attendant metainformation handling.

What are expected performance issues inherent to different approaches?

The relevant platform is average home desktop PC.

**Tags:** opengl, rendering, projections, video

> **Comments:**
> **username_0**: There is a lack of `360 panorama`, `cubemap` (!), `codec` and other relevant tags on computergraphics.stackexchange.com.  
> **username_1**: If you do not use the mobile interface then you can make new tags if you wish.  

---

## 1 answers

### Answer by username_2 on 2017-07-28. Score: 1

I would be tempted to use a solution which involves decoding a single rectangular video stream so you don't need any special video decoder. As you have said there will be performance penalties for decoding multiple seperate streams.

Something like octohedran cube maps might be a good offline way to convert 6 video streams into a single video stream while minimizing distortion. A relatively cheap pixel shader can be used to project the 'cube' map back to camera space.

Further reading here > <http://www.vis.uni-stuttgart.de/~engelhts/paper/vmvOctaMaps.pdf>

> **Comments:**
> **username_0**: Non-pyramid view frustum is not supported by rasterisators, but we use ray-tracer and it may have sense in our case. Also pixel density can be adjusted to be one-to-one on resulting flat video, but still pixel density is not uniform in case of octamap.  
> **username_0**: Currently "3x2-unfolded" video is used. The video looks seamless. No edges, no distortion on the first (and second) glance. Only four edges are glued and ten are onto the outer boundary. Currently used codec is randomly chosen and it is a luck, that there is no notable seams. (OpenGL supported) cubemap is a way to avoid geometry and filtering on glued and outer edges at all. It is interesting to try octamap, but presumably it have more distortion on the one hand and less glued and outer edges OTOH. Pixel to pixel mapping is impossible in case of non-cube Platonic solids.  

---

