Creating a Stereogram with GIMP
Posted 01 June 2005 - 01:06 AM
Infinity Stereogram by Fencepost
You've probably seen the famous Magic Eye products. Their publications seem to be the most popular. You can view their website here. For those that are "stereogram challenged", the site also has some viewing tips.
Magic Eye Website
I learned the techniques for creating stereograms from a gentleman named Gary Priester. Gary uses a vector graphics program called Xara X, which is a very sophisticated piece of software. Unfortunately, I can't justify spending the money for Xara X, so I adopted his techniques to GIMP. Gary's tutorial can be found here: XaraXone Stereogram Tutorial
Some of Gary's stereograms can be viewed here: Gary's Featured Art
Special thanks to Gary for bringing the creation of stereograms to the rest of us!
This will be a multi-part tutorial, with this first installment covering very primitive stereograms. I will be using GIMP and
Stereogram Maker 2.1 for these lessons. Download Stereogram Maker Here
There are certainly other, more sophisticated programs out there that can create these images, but this one is free! If it's free, it's for me!! If you use a different program, you'll have to follow the software's instructions for creating them.
EDIT (June 9, 2005. 8:54 AM): I have switched my stereogram program of choice to 3D Miracle, which can be downloaded here: 3D Miracle Website. The free version will only allow you to create 640X480 size stereograms. Which is good for most people. The registered version ($25 US) will let you create them in any size. 3D Miracle is a bit more user friendly with more adjustable parameters.
Since my tutorials were created with Stereogram Maker 2.1, I will still answer any questions that may arise regarding the use Stereogram Maker 2.1.
From here on out, I will be referring to Stereogram Maker as SM, to eliminate some typing. SM is a Windows only product. Sorry Linux users, you'll have to find a stereogram for your operating system. However, creating the required Depth Map in GIMP will apply to you. So, you're not excluded entirely!
Stereograms essentially contain two images to create the 3D effect. The first image is the Depth Map or Range Image as referred to by SM. The second image is the texture or pattern image as referred to by SM.
Depth maps (Range Images) are made up of black, white, and gray colors. The computer software takes white and brings it to the front, black is sent to the back, and shades of gray fall in-between the two. As you can guess, the lighter shades of gray appear closer than darker shades of gray.
Textures or Pattern Images, can be any texture. However, it is recommended you use a texture that is very random, as the stereogram software will distort the texture to hide the depth map within it. SM, as well as most other stereogram programs, will also create textures for you. For this tutorial, I will be using this function for simplicity sake. You may, however, use any texture you wish.
Well, Now I'm finished with all the background information. Let's begin Installment 1!
[*]Open up a new GIMP document (any size, but I will be using 640X480) with a black background.
[*]Grab your text tool and choose a fat font and make its pixel size quite large.
[*]Add some white text. I'm typing in the word GIMP.
[*]Flatten the image and save it as a .jpg.
Here's what mine looks like...
Congratulations you've just created your first depth map!
WHAT!? Say, it isn't so, Art!! It really can't be that easy. Well, for our first example, it is that easy.
Now, let's open up SM (or if you're using another program, open up you stereogram software)
[*]Click the "Open a file button"
[*]Select the Depth Map (or Range Image) we just created.
[*]Select the "Range Image" option from the dialog box
At this point you could go back up to the "Open a File" button and open up a texture image, but we'll let SM make one for us. Remember, if you use one of your own, make sure it has a lot of randomness to it. Also, if you use one of your own, you need to select this button on the dialog box...
VERY IMPORTANT: If you brought in your own pattern, go now to step B, otherwise go to Step A, then to Step B
[*]STEP A - Click the "Create Random Coding Pattern" button....the 3rd button at the top left: You can select either texture color option, but I prefer the colored one.
[*]STEP B - Click the "Create Stereogram from Range Picture" button
Congratulations! You are the proud owner and creator of your first stereogram!! Be amazed and impress your friends!
Before you exit SM, right-click the stereogram and save it.
Yeah, I know it's bland, but this is a work in progress.
Now, while I'm preparing the next installment, you experiment a bit. Make some circles, squares, text, whatever and experiment with different levels of gray. Make one object white. Add another object next to it and make it a little darker. Shoot, add a third object and make it even darker. Make sure your background is black. See what you can come up with.
I'll add more later. I'll be here all week. Make sure you tip your waitress.
Posted 03 June 2005 - 04:14 AM
Good day and welcome to Installment #2 of Creating A Stereogram in GIMP. I'm your host, Fencepost and with this portion of our lesson, we will be expanding upon our most recently learned knowledge to add some depth to the stereograms.
To simplify matters a bit, I will not be going back over Installment 1. I will be referring to those steps every now and then, but won't be explaining each and every move to get there.
A "flat" appearing stereogram is cool in-and-of itself. But, we're really looking to create the appearance of depth in our images. If you practiced on your own as I suggested at the end of our last lesson, you were probably able to come up with some pictures that had some semblance of depth. However, just in case you didn't practice, we'll do it now.
[*]Let's open up a new image with a black background and add three rectangles. Color each rectangle with a different shade of gray.
[*]Flatten and save the image.
[*]Open up your stereogram program and create a stereogram with the image.
What do you see? If your colors resemble mine as shown above, the center rectangle will appear closer to you, the one on the left will appear a little further back, and the one on the right will appear even further back.
Now that we've experimented with adding depth between separate objects, let's add depth to individual objects. We'll be using text for the next two examples, but I'll warn you right up front, text is kinda funky to add depth to. Even using very fat fonts don't seem to have much depth. Maybe it's just that I haven't learned a good technique for it, but for now, we'll be using only two individual, very large letters to add some depth.
[*]Open a new image with a black background.
[*]Add a very large letter and make it white (or any shade of gray, for that matter)
[*]Duplicate the letter, but this time change your foreground and background colors to a light gray and a dark gray.
[*]Drag a shaped (spherical) gradient across this second letter.
This is my result.
[*]Create a stereogram.
What do you see? Mine has the one on the left as being flat and the one on the right as having some depth.
Are you beginning to see how we can create some really cool things?
Here's a second image patterned after the one above. The letter on the right has the same color gradient as the one on the right from above. The letter on the left appears to have no color gradient, but it does--a very small one.
[*]Create a stereogram.
Notice how the one on the left has some depth to it, but is a little bit smoother? Your naked eye might not have been able to detect the depth, but under the stereogram, it's very apparent.
For our last exercise, create an image as below. Add a radial gradient to each circle, but change up the amount of gray for both the foreground/background colors in each circle.
[*]Create a stereogram.
Well, I hope this has been fun for you so far. I think we've developed our skills enough to take this to another level. In the next installment, we'll be creating a stereogram of the infinity symbol as referenced at the very beginning of the tutorial.
Until then, I'm off to bed.
See ya soon. Art
Posted 05 June 2005 - 07:15 PM
Let's recap a bit. I've tried to lay out these lessons in a "foundational-type" strategy, where every concept learned will be used as a base for the next.
[*]In our first lesson created a very basic stereogram with nothing but a white object on a black background. When we viewed the stereogram, we were able to see the depth created by the computer using just two colors.
[*]In the next session, we added a bit of dimension between objects by making one object one shade of gray and the next object another shade of gray. The first exercise gave our eyes the sensation of three rectangles occupying different positions in space. We also created depth within individual objects through the use of gradients. Our examples using the letters and circles showed that individual objects could appear to have a 3D feel to them.
Now that we've prepared this foundation, let's add another "brick" to the building.
This lesson will utilize both concepts: We will create an infinity symbol (essentially the #8 lying on its side) that looks like it has depth from front to back (Installment #1). We could stop there and have a really cool stereogram (albeit flat, it would have depth), but we now have the tools from Installment #2 to carry us even further....We will now add an additional gradient on top of the infinity symbol to make it look like a twisted pipe, rather than a twisted piece of paper! This is really cool and very straightforward.
To avoid confusion, I will be describing in detail almost every step I took to create this object. You experts out there will most likely say that this could have been done in a much simpler fashion, without as many steps. I agree wholeheartedly. But this is for ALL GIMP users of every level. So, just follow along.
[*]Open a new 640X480 document with a transparent background. The background will utimately be filled with black, but I get tired of looking at a black screen for extended periods and went with black.
[*]Duplicate this layer and rename it "Upper Left"
[*]To help us line things up later on, let's add some guidelines. An easy way to do this it to go to Image | Guides | New Guide...We'll be adding 7 guides, so you'll have to go through this menu for each one.
You could manually drag them into position, but I'll let the computer position them for me. Yeah, I'm lazy, but I'm also doing the tutorial :w:. Make sure you turn on Snap to Guides ...View | Snap to Guides
Add three horizontal at: 100, 235, and 370
Add four vertical at: 70, 205, 340, and 560.
(The yellow numbers will not appear on your screen, this is just for those who don't like to read all the steps!!)
[*]Make the Upper Left layer active.
[*]Now grab your ellipse selection tool and, at the intersection of guides 100 and 70, drag a circle down to the intersection of guides 370 and 340. Because we have turned on the snap to guides, you don't really need to hold down the shift button while dragging the circle.
The way we set up the guides should form a perfect circle.
[*]Fill your circle with any color. At this point the color doesn't really matter.
Here's what mine looks like.
[*]With the circle still selected, shrink the selection by 50 pixels. Select | Shrink...50
[*]Delete the inner selection by selecting Ctrl-K
You should now have a "colored donut."
Now, we need to start giving our depth map, some depth.
[*]Change your colors like so..
[*]Set the Upper Left layer mode to "Keep Transparency"
[*]Grab your Gradient Tool and, using the Conical (sym) shape tool, fill the circle like so..
Your results should look similar to this....
Now, we're gonna start cutting the main object to create the overall symbol shape.
[*]Grab your rectangle selection tool and select the lower half of the circle.
[*]Now, cut the bottom half (Ctrl-X) and paste it back (Ctrl-V). This will create a floating selection. Before you anchor the layer, grab your move tool (4-headed arrow) and snap the lower half back to its original location. Click the new layer button and the floating selection will automatically be anchored to the new layer.
[*]Rename this layer to "Lower Left"
[*]Now let's change the colors of this layer. I'm using these colors...
Remember to set the "Lower Left" layer's blend mode to "Keep Transparent" as we did above.
[*]Again, like before, grab your Gradient Tool and, using the Conical (sym) shape tool, fill the bottom half of the circle.
Do you see where this is going? Beginning at about 3:00 on the circle, you have the most white in the image. This will appear the most forward in the stereogram. As you move counter-clockwise, the circle will gradually "twist" toward the back.
Let's move on....
[*]Duplicate the Upper Left and Lower Left layers.
[*]Now, make one of the duplicates active and rotate it 180 degrees....Layer | Transform | Rotate 180 degrees.
[*]Do this for the other copy.
[*]Now position the new duplicates so your image looks like this...
[*]Arrange your layers so they are in this order...
We're now heading towards the home stretch. This is where it gets good!
We could stop right here, flatten the image, save it, and create a nice looking stereogram; however, we've only completed one of the concepts I promised at the beginning of this installment. We've given our image the gradient to look like it has depth from front to back, a "flat, twisted piece of paper", so to speak. But, let's make our infinity symbol appear as if it has depth from side to side, or a twisted pipe.
[*]With the four half-circle layers visible, merge them together to form one symbol. Image | Merge Visible Layers (Ctrl-M). This should leave you with only two layers: one with the infinity symbol, the other the background layer.
[*]Change your foreground and background colors like so.
[*]Set the upper layer's blending mode to "Keep Transparent"
[*]Double-click the "Gradient Blend" tool button and set its setting as follows:
Drag the Gradient Tool across the image as above and your image should look like the following.
For the last few steps
[*]Fill your background layer with solid black.
[*]Flatten your image and save it.
[*]Open up the image in your favorite stereogram program and create a stereogram with it.
You are FINISHED!!! How did you do?
Well, I hope this was fun, but more importantly, I hope you've expanded your capabilities with GIMP. There are a few more things I want to add to this tutorial, but I haven't grasped them yet myself. But when I do, I'll let you in on those secrets!
As with all of my tutorials, if I've left something out or haven't properly explained it, please let me know. Also, I'd like to hear your feedback on this.
Thanks and have a great day.
Keep on GIMPing!
Posted 12 January 2007 - 05:00 PM
I am dan99iel on Wiichat! You will see dan99iel on my sigs!
Posted 28 January 2010 - 03:40 PM
Used this pattern, and this depth map to create the ME below (need a wide enough screen to see it; mine is). :)
Images hosted free thanks to ImageShack (http://www.imageshack.us).
Posted 07 February 2011 - 05:07 AM
For Linux users who would like to use Fencepost's tutorial for Stereogram Maker, SM should run under Wine just fine. (I recommend looking in your distro's repositories for Wine.)
Posted 07 February 2011 - 05:59 AM