I’ve been creating 360-video experiences in Unity through the use of MovieTexture, using panoramic videos with an aspect ratio of 1436 x 718. This has been working fine for me for the last year.
Now I’m trying to use a new 360-camera, the 360-Fly. The Fly camera produces mp4 whose size is perfectly square, say 800 x 800. I’m able to apply these as textures to the inside of my spheres, but the image is distorted.
How would change the way the material/texture is applied to the mesh? In this case I want the center of the video image to appear at the apex of the sphere and the four corners of the square material converge at the bottom of the sphere. How would I do this?
Below are images of the wide pano that’s been working for me, and the new square pano I want to apply to the inside of a sphere.
@pkiriakou, I never solved this specific issue, but the answer as I understand has something to do with creating the correct UV map for the sphere. I still haven’t done the deep-dive into 3D modeling and subjects like creating UV maps, but apparently that’s the direction to go in order to solve this problem.
Glurth
3
“The Fly camera produces mp4 whose size is perfectly square, say 800 x 800.”
Actually, it looks like the image it produced is perfectly CIRCULAR. What this means, is that when you map your texture UV coordinates onto the sphere, you will want to IGNORE those corners which hold no image.
Also, you mention you are trying to map this onto a sphere: however the image is only a DOME, or half a sphere.
Given a dome mesh, of diameter 1.0f, with the top of the dome pointing at +Y:
I would simply set the UV of each vertex based upon the x,z coordinate of that vertex (offset to center on the dome’s apex).
Something like this (untested):
VertexUV<em>= Vector2(VertexPosition_.x,VertexPosition*.z) +Vector2(0.5f,0.5f);*_</em>