Easy way to convert cubic panorama to equirectangular panorama [1 Attachment]

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Easy way to convert cubic panorama to equirectangular panorama [1 Attachment]

PanoTools NG mailing list
Hi,

I am looking for a fast and easy way to convert a cubic panorama (12 tiles with 2048x2048 see png file for principle structure) into an equirectangular panorama.
At the moment we are using the following approach for jpg versions.

A script using ImageMagick and batch commands (Windows 7) does the following:
1) make 12 tiles from the cubic panorama jpg with Imagemagick (convert crop)
2) delete the 6 black tiles and rename the others to ..._0 until ..._5
3) mirror the one tile horizontally and vertically that was on the last side (convert flip flop)
Afterwards we back the 6 cube side together with pano2qtvr.

If we only get an mov panorama (instead of jpg) we use Adapter or similar programs to extract the cube sides and then delete and rename them manually.
Is there a simpler way (with freeware)? Is HUGIN able to convert panoramas?

 Looking forward to helpful answers,
 

 Sebastian

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: Easy way to convert cubic panorama to equirectangular panorama

PanoTools NG mailing list
Hi Sebastian,

 

I found a couple references below:

 

http://panotools-ng.586017.n4.nabble.com/Cube-faces-to-equirectangular-in-PTGui-td2262677.html (follow the link to Erik Krauses site)

 

https://groups.google.com/forum/#!topic/ptgui/dclLhdN5R1I

 

I think these pre-suppose that you have six cubefaces in separate files though, so it looks like you still need to do the first step of splitting your original image apart into cubefaces. Once that is done, however, you can use PTGui to stitch them back together into an equirectangular image. Once you have that working the way you want it, save it as a template which you can then call from the Batch Stitcher for future use.

 

Mark

 

From: [hidden email] [mailto:[hidden email]]
Sent: Wednesday, February 22, 2017 7:59 AM
To: [hidden email]
Subject: [PanoToolsNG] Easy way to convert cubic panorama to equirectangular panorama [1 Attachment]

 

[Attachment(s) from [hidden email] <mailto:[hidden email]>  [PanoToolsNG] included below]

Hi,

I am looking for a fast and easy way to convert a cubic panorama (12 tiles with 2048x2048 see png file for principle structure) into an equirectangular panorama.
At the moment we are using the following approach for jpg versions.

A script using ImageMagick and batch commands (Windows 7) does the following:
1) make 12 tiles from the cubic panorama jpg with Imagemagick (convert crop)
2) delete the 6 black tiles and rename the others to ..._0 until ..._5
3) mirror the one tile horizontally and vertically that was on the last side (convert flip flop)
Afterwards we back the 6 cube side together with pano2qtvr.

If we only get an mov panorama (instead of jpg) we use Adapter or similar programs to extract the cube sides and then delete and rename them manually.
Is there a simpler way (with freeware)? Is HUGIN able to convert panoramas?

Looking forward to helpful answers,

 

Sebastian








Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Easy way to convert cubic panorama to equirectangular panorama

PanoTools NG mailing list
Hi Sebastian
if you have 6 cube projection, the easiest way to convert them into an
equirectangular panorama is

http://nadirpatch.com/cube2sphere/

NadirPatch.com team

2017-02-22 14:25 GMT+01:00 'Mark D. Fink' [hidden email]
[PanoToolsNG] <[hidden email]>:

>
>
> Hi Sebastian,
>
>
>
> I found a couple references below:
>
>
>
> http://panotools-ng.586017.n4.nabble.com/Cube-faces-to-
> equirectangular-in-PTGui-td2262677.html (follow the link to Erik Krauses
> site)
>
>
>
> https://groups.google.com/forum/#!topic/ptgui/dclLhdN5R1I
>
>
>
> I think these pre-suppose that you have six cubefaces in separate files
> though, so it looks like you still need to do the first step of splitting
> your original image apart into cubefaces. Once that is done, however, you
> can use PTGui to stitch them back together into an equirectangular image.
> Once you have that working the way you want it, save it as a template which
> you can then call from the Batch Stitcher for future use.
>
>
>
> Mark
>
>
>
> *From:* [hidden email] [mailto:[hidden email]]
> *Sent:* Wednesday, February 22, 2017 7:59 AM
> *To:* [hidden email]
> *Subject:* [PanoToolsNG] Easy way to convert cubic panorama to
> equirectangular panorama [1 Attachment]
>
>
>
> *[Attachment(s) <#m_-4391315610531642579_TopText> from
> [hidden email] <[hidden email]>
> [PanoToolsNG] included below]*
>
> Hi,
>
> I am looking for a fast and easy way to convert a cubic panorama (12 tiles
> with 2048x2048 see png file for principle structure) into an
> equirectangular panorama.
> At the moment we are using the following approach for jpg versions.
>
> A script using ImageMagick and batch commands (Windows 7) does the
> following:
> 1) make 12 tiles from the cubic panorama jpg with Imagemagick (convert
> crop)
> 2) delete the 6 black tiles and rename the others to ..._0 until ..._5
> 3) mirror the one tile horizontally and vertically that was on the last
> side (convert flip flop)
> Afterwards we back the 6 cube side together with pano2qtvr.
>
> If we only get an mov panorama (instead of jpg) we use Adapter or similar
> programs to extract the cube sides and then delete and rename them manually.
> Is there a simpler way (with freeware)? Is HUGIN able to convert panoramas?
>
> Looking forward to helpful answers,
>
>
>
> Sebastian
>
>
>
>
>
>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Easy way to convert cubic panorama to equirectangular panorama

PanoTools NG mailing list
Am 22.02.2017 um 14:37 schrieb Nadir Patch:
> if you have 6 cube projection, the easiest way to convert them into an
> equirectangular panorama is
>
> http://nadirpatch.com/cube2sphere/

...but note that they don't accept single cube face images larger than 20MB.

--
Erik Krause


------------------------------------

------------------------------------

--
<*> Wiki: http://wiki.panotools.org
<*> User Guidelines: http://wiki.panotools.org/User_Guidelines
<*> Nabble (Web) http://panotoolsng.586017.n4.nabble.com/
<*> NG Member Map http://www.panomaps.com/ng
<*> Moderators/List Admins: [hidden email]

------------------------------------

Yahoo Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/PanoToolsNG/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/PanoToolsNG/join
    (Yahoo! ID required)

<*> To change settings via email:
    [hidden email]
    [hidden email]

<*> To unsubscribe from this group, send an email to:
    [hidden email]

<*> Your use of Yahoo Groups is subject to:
    https://info.yahoo.com/legal/us/yahoo/utos/terms/

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Easy way to convert cubic panorama to equirectangular panorama

PanoTools NG mailing list
In reply to this post by PanoTools NG mailing list
Thanks for the advises and tips.

But I am looking for a freeware tool solution (offline).
Does anybody has a Windows version of the tool CUBE2ERECT ?

Greetings,

Sebastian
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Easy way to convert cubic panorama to equirectangular panorama

PanoTools NG mailing list
Am 26.02.2017 um 12:12 schrieb [hidden email]:
> Does anybody has a Windows version of the tool CUBE2ERECT ?

 From http://search.cpan.org/dist/Panotools-Script/bin/cubic2erect

"'cubic2erect' is a command-line utility program for converting six cube
faces to a single TIFF format equirectangular file suitable for viewing
with 'panoglview'."

So at best you can replace pano2qtvr but not the other steps.

Since cubic2erect is part of panotools-script you might get some hints
on http://wiki.panotools.org/Install_Panotools-Script_on_Windows

Also probably helpful:
http://wiki.panotools.org/Panorama_scripting_in_a_nutshell

And yes, hugin should be able to do this, too.

Erik
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Easy way to convert cubic panorama to equirectangular panorama [3 Attachments]

PanoTools NG mailing list
Hi,

Thanks your suggestions and hints.

 For the part cubic sides to equirectangular panorama I worked out the following solution:
I analyzed the "cubic2erect" http://search.cpan.org/dist/Panotools-Script/bin/cubic2erect script and it won't work with the current version of Hugin 2016.2 (nona.exe). All tries with PT Tools (pano12.dll) were either frustrating or terrible slow.

Therefore I created a batch script (Cubesides2Equirect.cmd for Windows 7) converting cube sides automatically using HUGIN.
It is either possible to use a specific file name or a wildcard (no input = *.jpg)  for the input of cube sides. It will create a PTO script (HUGIN) that will be executed automatically (with hugin_executor.exe). Later on it is also usable by means of "double click" with HUGIN GUI.
It is the fastest way I found for mass conversion (lots of cubic panoramas converted into equirectangular panoramas).
If you use Windows you are welcome to try the script (Cubesides2Equirect.cmd).
It uses HUGIN 2016.2 (for other versions change variable HUGINPATH) and ImageMagick 7.01 (for other versions change variable IMMAGICK) . ImageMagick  is used to determine the cube size (width). Without ImageMagick  it is set to a fixed value (variable CUBEWIDTH). A template script "template.pto" is also used.

Before use try "Cubesides2Equirect.cmd -h" for help.


 For the part cubic panoramas to cube side I worked out the following solution:

 I created a batch script (JPG2Cubesides.cmd for Windows 7) converting cubic panoramas automatically to cube sides using ImageMagick. It is analyzing the cubic panorama for the ratio width/height and detect 5 cubic structures:
vertical cross, horizontal cross, vertical line (Gear VR or plain) and horizontal line (Panorado viewer = plain).
First the panoramas are cut in 12 or 6 equal sized tiles. Afterwards the "black" tiles are deleted (can be disabled) and the remaining tiles are renamed for use with PANO2QVTR or my own script (see above) as:
*_0.jpg = front side
*_1.jpg = right side
*_2.jpg = back side
*_3.jpg = left side
*_4.jpg = top side
*_5.jpg = bottom side
 
If you use Windows you are welcome to try the script (Cubesides2Equirect.cmd).
It uses ImageMagick 7.01 (for other versions change variable IMMAGICK).

Before use try "JPG2Cubesides.cmd -h" for help.
If you have considerable cubic panorama formats I can implement them into the script.

 For the part mov panoramas to cube side I use the following solution:
Ken Silverman (http://advsys.net/ken/kube/kube.htm) wrote a simple and fast program called qmov2jpg.exe converting mov panoramas into cube sides (low and high quality). I am testing a script (using
ImageMagick) to determine automatically the correct order and rotation of each resulting cubic side (not finished yet). qmov2jpg.exe is faster than the Adapter solution as less steps are necessary and it can be batched [used in batch scripts :)].


 


Loading...