A 3D anaglyph image will appear three-dimensional when viewed through red/blue lenses. Here is technique for creating 3D anaglyphs in The GIMP, submitted by reader Angel D. Guzman after adapting the Photoshop anaglyph tutorial by Dan Payne. This tutorial was written for The GIMP 2.2.11, but later versions should also work.
Time Required: 10-20 minutes
- Obtain two stereo pair photos. (I often use two disposable cameras mounted on a board side by side and with an ever so slight convergence towards the horizon. Remember you're mimicking your eyes and your eyes always end up focusing on something--each eye can never look straight ahead separately. I find the best anaglyphs work with a very low level of convergence. This is usually evident by the amount of red/cyan silhouetting around objects in a scene.)
- Scan each photo separately. (I would recommend desaturating them to make them B&W.)
- Open right photo in The GIMP (just like your eye, the right photo is identifiable by the fact that objects within the scene are more to the left when overlayed with the other eye.)
- From the color selector, select color #FF0000 (bright red). The equivalent of this in RGB is R-255 G-000 B-000.
- Create a layer above the right photo and fill it with this color.
- Duplicate this layer and go to Layer > Colors > Invert. This will change the color of this duplicate red layer to a cyan color (direct opposite). In RGB the color created will be R-000 G-255 B-255.
- Select the red layer. Go to File > Open as Layer and open the left photo.
- Step #7 will put the left photo just above the red layer and you should now have 4 layers in the following order: The bottom is your right photo. Above it is the red layer. Above it is the left photo and above this is the cyan layer.
- If you wish to check the alignment of the two photo pairs you can turn off red and cyan layers and adjust the opacity of the left photo to 50%. Make sure both photos are on the same vertical plane and shift up/down appropriately. When finished change the opacity of the left photo back to 100%.
- Turn on the cyan layer and change the transfer mode to screen (This is the Mode selection box in the layers dialog box right above opacity).
- Turn off the lower layer (the right photo) and the red layer by clicking on the small eye icon they have to the left side.
- Merge the cyan and left photo layers together. To do this go to Image > Merge Visible Layers and then click OK in the Merge Layers dialog box that appears. You should now see a very abstract cyan tinted image that will be hard to distinguish in areas.
- Turn off this new cyan layer.
- Turn the red and right photo layers back on and change the red layer transfer mode to screen. Then merge them in the same way you merged the cyan and left photo layers in step 12. (Note: You don't need to merge these two if you don't want to.) Again you'll see an abstract red image similar to the cyan before.
- Turn on the new merged cyan/left photo layer and select it. Change the transfer mode to multiply. Put on glasses (red on left, cyan on right) and you should now see the anaglyph.
- You may wish to change the red/right layer's opacity to somewhere between 80 and 90%. Do this as you wear the glasses as it will make the adjustments easier. Remember in order to do this you need to add a white layer below the right photo (or red color/right photo merge) so you don't see the transparency squares beneath the photo if you started with a transparent background. You could also move this layer left or right to make adjustments to the alignment.
- At the end you can merge down the image by going to Image > Flatten Image and save it as a JPEG image with the quality setting of your choice for simplicity so you don't have to save it as a layered GIMP .xcf picture.