Page 1 of 2
6 images (cube map) into equirectangular?
Posted: 2015-08-31T13:01:26-07:00
by stuka
I need to convert 6 images (up, down, left, right, front, back) into 1 equirectangular image.
Such as these:
into something similar to this:
There are probably some image editors which can do this. Thing is, I have a video, so need to batch convert. Can use the command line tool too, and just put the command in a loop.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T13:06:36-07:00
by snibgo
That input won't transform to that output. One looks like the sky, the other looks like the Greek island of Santorini.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T13:18:01-07:00
by stuka
imagine the first is also Santorini.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T13:43:19-07:00
by Bonzo
Doing a search it looks like the OP wants to do this:
http://paulbourke.net/miscellaneous/sphericalpano/
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T14:15:02-07:00
by snibgo
I can hardly see the small input, but the horizontal part doesn't look like four rectilinear images. It looks like a cylindrical projection. If the OP provided corresponding inputs and outputs, we could see.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T22:40:51-07:00
by stuka
Bonzo's page has some example images. So does this page
http://stackoverflow.com/questions/2967 ... o-cube-map
snibgo, I'm sorry I don't have better corresponding inputs and outputs. I'd make some, but I don't know how to convert between the two that's why I'm posting here.
Cubemap and equirectangular are projection/mapping types you can learn about on wikipedia.
https://en.wikipedia.org/wiki/Cube_mapping
https://en.wikipedia.org/wiki/Equirecta ... projection
If explanation of equirectangular is confusing from the above link, maybe this explanation will help: it's unwrapping an image from a sphere (sphere map?) to a 2x1 rectangle.
I hope it's clear now.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-08-31T23:45:48-07:00
by fmw42
IM does not have projection mapping built in. I have some very slow scripts that do some. See fisheye2pano and fisheye2rect and defisheye and pano2rect at the link below. I have not done any cube mapping.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-09-01T02:46:59-07:00
by stuka
Yeah, you have some nice scripts there but none could be used in some way to turn 6 cubemap images into equirectangular sadly.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-09-01T05:19:53-07:00
by snibgo
I can learn about many things on Wikipedia. But I don't know which apply to your situation.
The Wiki page on cube mapping show the horizontal stripe as four rectilinear images, like ordinary photographs, where straight lines in real life remain straight in the image. But the single input you have provided so far doesn't look like that.
If all your images require the same transformation, a displacement map could be built and applied to each (perhaps with supersampling). It wouldn't matter if building the map with "-fx" was slow, because it would only be done once.
You say you have a video to convert. Please provide some sample frames.
Re: 6 images (cube map) into equirectangular?
Posted: 2015-09-01T06:25:54-07:00
by jules43
It's possible Pano2VR will do what you want.
http://ggnome.com/pano2vr
Re: 6 images (cube map) into equirectangular?
Posted: 2015-09-01T14:14:51-07:00
by stuka
snibgo wrote:You say you have a video to convert. Please provide some sample frames.
Actually I have a 3d program where I make 3d animations, "video" was probably the wrong term to use, it's a 3d animation right now, not yet rendered to a 2d video.
But I really don't understand why you still want a sample. I've given you already. You don't need mine specifically.
Here's more:
http://paulbourke.net//geometry/transfo ... l#cube2cyl
Re: 6 images (cube map) into equirectangular?
Posted: 2017-02-20T04:35:10-07:00
by Plau
Hi,
Thanks for posting this. I am having a very hard time to find out how to create an equirectangular image from 6 images.
I've tried Pano2VR, PTGui, and many more but it seems impossible to stitch these images.
My images don't have EXIF data as they have been designed in the computer. They are computer generated basically.
Does anybody have any idea of how to stitch these images?
Thanks!
Re: 6 images (cube map) into equirectangular?
Posted: 2017-08-12T05:13:27-07:00
by jumpjack
I have a similar, but "reverse" need: I'd like to get multiple images from a spherical image. Each of the multiple images should show what I'd see looking toward a specific direction in the sphere. But I don't know which projections are involved, any help?
Re: 6 images (cube map) into equirectangular?
Posted: 2017-09-18T15:12:12-07:00
by fmw42
I have just created 2 new scripts to do both these directions, cube2sphericalpano and sphericalpano2cube. Note that they will be slow due to the use of -fx to do the transformation. See my link below for the scripts.
Re: 6 images (cube map) into equirectangular?
Posted: 2017-09-19T02:19:50-07:00
by jumpjack
This looks interesting, but the script sphericalpano2cube can only "look" left, front, right, back, over, under; I'd need to be able to specify how many degrees to look "left" or "right" (not just 90° or 270°).
The final objective is to constantly look (virtually) at the same object while moving parallel to it.
I'll try to explain better: I make a 360° video while moving ahead and the object is on my right; on each frame, the object will appear in a different positions: intially at 20°, then 40°, then 60°.... up to 160°. If I can extract a view with each of these headings from each frame of the video, I'll be able to create a new video which looks like I was moving around the object.