Printable Version of Topic

Click here to view this topic in its original format

Unmanned Spaceflight.com _ Image Processing Techniques _ Making anaglyph images

Posted by: stewjack Aug 17 2012, 09:20 PM

I have found more than one good program to make anaglyphs from the same size images of the L & R HAZ and NAV Camera's, but for long baseline anaglyphs you need to do something called "registering" one of the images with the other. Five years ago I had such a program, but not any longer.

Questions
OS Windows 7

1. Does anyone know of such a program that is simple and effective. It doesn't have to be free - but not more than $100!

2. (GIMP) I can create anaglyphs using a Gimp plug-in, if I import the two images as layers. What I haven't been able to figure out is how to make the top layer transparent. Then assume I could slide the top layer around until it is registered.

Can anyone tell me how to adjust the transparency of the top layer?

Gimp is such a pain I would probably pay for a program if I did much of this. I spent about 20 hours messing about with Gimp without getting anywhere. It was only when I accidentally imported color images that the plug-in worked! So now I "increase" the color depth in my images (using Irfan), and save them out as grey-scale images with something called a "color space." It works! What can I say, the plug-in was last updated in 2008! I would love something more automated, but I won't be using it that much.


Posted by: mcaplinger Aug 17 2012, 09:48 PM

QUOTE (stewjack @ Aug 17 2012, 02:20 PM) *
1. Does anyone know of such a program that is simple and effective.

Free. http://stereo.jpn.org/eng/stphmkr/

Posted by: stewjack Aug 17 2012, 10:56 PM

QUOTE (mcaplinger @ Aug 17 2012, 04:48 PM) *
Free. http://stereo.jpn.org/eng/stphmkr/


How does it register two images if the images are of different sizes, and/or slanted at a different angles? Does it make the second image semi-transparent so that you can register one image with the other easily.

Lets say the Rover drives 200 meters latterly (long base line), but the crater is 20% bigger in the second image because the rover has also driven 100 meters closer to the crater. Lets also say one image was taken by the Mastcam camera and another by a NavCam camera.

I made an anaglyph from crops of two MARDI images. There had been both quite noticeable rotation and altitude changes between the two images. After many hours I got an anaglyph that was barely worth the name. Heck I will upload it because I can no longer trust my own judgement about its quality. The craters keep turning into mounds. Remember I didn't try for accuracy just a 3d effect. Does it have a 3d effect? These are much easier to do if you have the correct program.

EDIT Actually I double checked and there was actually little rotation.

http://mars.jpl.nasa.gov/msl-raw-images/msss/00000/mrdi/0000MD9999000476E1_DXXX.jpg
http://mars.jpl.nasa.gov/msl-raw-images/msss/00000/mrdi/0000MD9999000485E1_DXXX.jpg


Posted by: 3d_mars Aug 18 2012, 03:31 PM

QUOTE (stewjack @ Aug 17 2012, 02:56 PM) *
How does it register two images if the images are of different sizes, and/or slanted at a different angles?


Here is a link to the http://stereo.jpn.org/eng/stphmkr/help/index.htm. The page that specifically answers your question is http://stereo.jpn.org/eng/stphmkr/help/align.htm.

Posted by: stewjack Aug 18 2012, 07:01 PM

QUOTE (3d_mars @ Aug 18 2012, 10:31 AM) *
Here is a link to the http://stereo.jpn.org/eng/stphmkr/help/index.htm. The page that specifically answers your question is http://stereo.jpn.org/eng/stphmkr/help/align.htm.


Wow! Thanks! I did look at the user guide but did not notice, and therefore read,, the documentation.

That program certainly looks like it is worth a thorough test by me. However, I spent so much time trying to get Gimp to work,
that it will probably be a week or two before I have much free time!

Thanks again for your help

Jack




Posted by: JohnVV Aug 21 2012, 09:20 PM

QUOTE
2. (GIMP) I can create anaglyphs using a Gimp plug-in, if I import the two images as layers. What I haven't been able to figure out is how to make the top layer transparent. Then assume I could slide the top layer around until it is registered.

simple

open up the layer window and click on the top image
then move the slider to 50%

as for stereo images
NASA/AMES "stereo pipline" - free , but for Linux
Hyperion CV /cyclops - google code , a bit old and no longer worked on but works
http://code.google.com/p/hyperion-cv/
http://thaines.com/content/blogsection/3/6/
use svn
http://code.google.com/p/hyperion-cv/source/checkout
--win prebuilt --
http://thaines.com/content/view/38/8/
cyclops_win32_08-09-22.zip

but for cyclops YOU will HAVE TO MAKE YOUR OWN camera model

Posted by: stewjack Aug 21 2012, 11:53 PM

QUOTE (JohnVV @ Aug 21 2012, 04:20 PM) *
simple

open up the layer window and click on the top image
then move the slider to 50%

Thanks JohnVV! Now all I have to do is find the time to compare both programs. Stereo Photo Maker
vs GIMP with the Anaglyph plug-in. sigh

I should get around to it in a couple of weeks. It appears to me that the plug-in will not recognize grey-scale
image files unless they have been modified to have a color space. That creates a couple of extra steps.

It seems the the plug-in was last updated in 2008! Maybe an older version of GIMP would not have that problem. I am not
\going to worry about that until I see if GIMP with Anaglyph plug-in has any advantages over Stereo Photo Maker.

Jack

Posted by: jamescanvin Aug 22 2012, 07:21 AM

QUOTE (JohnVV @ Aug 21 2012, 10:20 PM) *
simple

open up the layer window and click on the top image
then move the slider to 50%


A better way of doing anagyphs in Gimp is to change the Mode of the top layer from 'Normal' to 'Addition'.

Posted by: jmknapp Sep 7 2012, 11:38 PM

It's pretty easy in photoshop:

open the left and right images
drag one of the images on top of the other to create two layers, don't worry about registration yet
close the file you dragged--not needed any more
change mode from grayscale to rgb
adjust levels for the right image: set Red to 0
adjust levels for the left image: set G and B to 0
for the layer on top, set blending mode to screen
now you can see corresponding elements in each picture and can try to align it in different ways with the move tool
adjust overall levels for each layer for best effect

Posted by: ElkGroveDan Sep 8 2012, 12:27 AM

QUOTE (jmknapp @ Sep 7 2012, 03:38 PM) *
It's pretty easy in photoshop:
..............
adjust overall levels for each layer for best effect

Et voila! Here's one I made from two photos of Yosemite National Park through an airplane window last week (@35,000 feet, roughly over Fresno, California with a 250mm lens looking East). Most of the time spent on it was cleaning up the low contrast, low saturation, color-shifted images that result when you try to take a photo through the three or four layers of plexiglass and glass of a modern aircraft window. But once I had the two cleaned up photos it was quite easy to turn it into a red-blue 3D image using Photoshop CS5 and steps similar to the process jmknapp described above.

 

Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)