gbSIRTS - Single Image Random Text Stereograms

Most users are familiar with stereograms, the random dot variety and those which use tiled images in the background. But stereograms can also be made using text - using characters where other types of stereograms use pixels.

gbSIRTS quickly and easily generates text stereograms - called Single Image Random Text Stereogram (SIRTS). gbSIRTS also has a "mosaic" mode which substitutes a small, colorful bitmap for each character.

See my Stereogram Information Center for background information on stereograms and my gbStereogram freeware program which supports the other types of stereograms.

gbSIRTS key features include:
  • Text-based stereograms (random and custom text)
  • Mosaic display
  • Stereogram shimmering
  • Animated stereograms
  • Gradient backgrounds
  • Colored text
  • Paint mode for manual depth mask generation
  • Text, Circle, Rectangle, and Fill paint tools
  • Multiple stereogram creation algorithms
  • Automatic depth mask generation for standard shapes
  • Import standard stereogram depth mask
  • Save image
  • Online update
Overview   Operation   Toolbar   Paint Mode   Menu   Change History

Download (ver 2.5, 1.0M)

Text Stereogram (3D image of 2 overlapping squares)

Mosaic Stereogram (3D image of 2 overlapping squares)

Gradient Background

Colored Text

Manual Paint Mode

Imported Depth Mask

Text Depth Mask

Return to top of document


Historically, the invention of the stereoscope in 1832 was the first time that 3D images could be viewed, made possible by using two separate images - one for each eye. But in 1990 it was demonstrated that a single image could also contain 3D image content. The first such single image stereograms used a background of apparently random dots which hid the 3D content - hence the name Single Image Random Dot Stereograms (SIRDS). Stereograms really took off when techniques were introduced for using images as the background, resulting in sharper, more colorful 3D imagery.

I've released a freeware program called gbStereogram which can generate both types of stereograms.

This page, however, describes a second freeware program call gbSIRTS which generates a lesser-known type of stereogram - one which uses text as a background. Stereograms with text backgrounds are called single image random text stereograms (SIRTS).

The Bad News
Text stereograms are generally not the most popular type of stereogram because they suffer from a more pronounced layering effect, whereby the 3D objects to appear to made of layers with pronounced separation. This also limits a text sterograms to no more than about 10 total layers before the brain has trouble visualizing the 3D image.

The layering affect also happens in random dot stereograms, but because the dots are small, graphical techniques can be applied which significantly smooth out the layering effect. The smoothing is particularly effective on sterograms which use image backgrounds.

Unfortunately, there are no layer smoothing techniques for text stereograms so while they are particularly convenient and fast to create using computers, text stereograms do not provde the colorful eye-candy of the other types of sterograms.

I've considered generating a custom font which might be used to smooth a text stereogram. The idea would be for the font to contain less white space and the font characters would not be applied randomly, but rather placed at level transition points to help smooth out the final image. I'll be looking into this approach and will add the results to gbSIRTS if it works out!

The Good News
The eye-candy problem aside, text stereograms are every bit as exciting to view. I'm addicted to 3D imagery in general and even the simplicity of text stereograms is fascinating. As a programmer text stereograms are particuarly exciting becausing text manipulation of a screen full of data is much faster than manipulation a screen full of pixels. gbSIRTS can generate text stereogram images, including animations, far faster than full size images.

There are other tricks which help close the gap. Most importantly, gbSIRTS uses a computer font which supports fonts down to size 6 - not dots, but small enough for most folks eyes to lose the distinction of individual characters.

The other good news about gbSIRTS is that while it contains built-in Paint functions to generate custom depth masks, it can also use the depth masks that are used to generate random dot and image background stereograms. This means you can search the Internet for find hundreds of existing mask which can be used in gbSIRTS.

Return to top of document

gbSIRTS Operation

Like most stereogram programs gbSIRTS uses a depth mask to define the depth level of each point (pixel) on the stereogram. gbSIRTS divides a depth mask, which is the same size as the stereogram, into a grid of elements. Each element is the size of the characters filling the stereogram.

When started the first time gbSIRTS automatically generates a text stereogram using one of the built-in depth masks. Pressing the "Create Stereogram" button will re-generate a new stereogram using the current depth mask. Pressing the "Shimmer" button will repeatedly create a steregraom using the current depth mask.

Use the "Shape" button to change to a new built-in depth mask, or to change to Paint Mode, to create a customer depth mask.

All of the features of gbSIRTS are accessed from the toolbar or from the Depth Mask frame which is displayed only when gbSIRTS is in Paint Mode

Depth Masks
gbSIRTS can import a depth mask from an existing file. It also allows the user to manually create a depth mask using simple built-in paint tools. The paint tools provide the ability to create depth masks from the following elements: square, circle, line, and text.

Built-In Depth Masks
In addition to allowing the creation of a custom depth mask, gbSIRTS can automatically create depth masks of three types - squares, circles, and bars. When a built-in shape is chosen from the toolbar, gbSIRTS automatically creates a depth mask with the selected shapes and will display it when the "Create Stereogram" or "Shimmer" commands are selected on the toolbar.

Note: In paint mode the custom mask is displayed, which the user can modify. Depth masks for the built-in shapes are not displayed in paint mode.

In paint mode, gbSIRTS can generate a depth mask with up to 8 layers. The layer is determined by the shade of gray used to make the depth mask image and gbSIRTS allows the selection of eight different shades.

Eight was chosen because it represents the maximum number of layers most users can easily visualize within a text stereogram.

When a depth mask is imported it may contain many more shades of gray than gbSIRTS provides. By default, all shades of gray that do not match one of the 8 default layers are placed in a 9th layer.

However, the "Use Custom Levels" context menu selection can be used to have gbSIRTS provide a finer control of the layers displayed in the 3D image. The context menu "Custom Levels" allows the user to attempt to display up to 40 total layers. In most cases, anything display with more than 10-12 layers is very difficult to see, but when visible the greater number of layers more accurately represents the imported depth mask.

Shimmer refers to repeatedly creating/displaying a new stereogram using the same depth mask. Shimmering is a means of helping view the 3D content. Even though each new stereogram has a different set of random characters, the 3D image remains constant and the act of repeatedly displaying the image within a changing background helps the brain focus on the hidden 3D image.

The animation capability of gbSIRTS can only be applied to the built-in depth masks. When both shimmering and animation are activated each successive stereogram will display the 3D images in a new position.

Pattern Width
The algorithm used by gbSIRTS calls for a specified number of characters to be used as the repeating stereogram background pattern. No one pattern width is best for all depth masks, so gbSIRTS allows the user to adjust the pattern width to optimize viewing of the stereograms.

Background Text
Even though a SIRTS is defined as a single image random text stereogram, the background text does not actually have to be random. A fixed background text can also be used. As part of creating the stereogram the background text is manipulated but remains easily distinguised in the resulting stereogram.

Colored Text
By default, gbSIRTS uses black text because when all of the characters are the same color the brain can readily detect level changes. By randomly colorizing the text the brain has more difficulty in detecting the 3D image. I added the colored text option just to be able to see experiment on the effect. You can still see the 3D images, but they are definitely more difficult to keep visualized.

Font and Character Set
The output font of gbSIRTS is set to 'Courier New', a fixed width font because fixed width fonts are most conducive to creating the 3D image within the stereogram. gbSIRTS supports selecting a new font, but using a variable width font will give poor viewing results.

gbSIRTS also allows the selection of 3 sets of characters within the font - all capital letters, all lower case letters, and all symbols (ASCII codes 33-122). The use of specific character sets changes the amount of white space, which impacts the ease with which the 3D image can be viewed. However, viewing is generally not greatly different with any of the three options, although some users may be more affected than others.

There are four separate algorithms available in gbSIRTS.

The first three are based on an algorithm which creates a pattern of text, then applies modified versions of that pattern repeatedly from left to right in the image. Two of the three algorithms are allowed to reuse characters from the pattern, while the third prevents the reuse of characters.

The fourth algorithm (which does not work very well as of release 2.0 - I'm working on it!) applies a totally different algorithm which positions text characters on the basis of the separation they would have on an image plane between your eyes and the 3D object being viewed.

My Stereogram Information Center provides more information on these algorithms.

Mosaic Display
Normally, gbSIRTS displays a text output but when the mosaic display option is selected, each character is replaced by a small, built-in bitmap. The result is a much more colorful display. Also, the 3D content is generally much easier to see.

The display of a mosaic takes about 0.3 seconds, so while the shimmering effect can be applied it will not repeat as quickly as plain text.

Save Images
The Save option of gbSIRTS saves the depth mask, or stereogram - whichever is visible at the time Save is pressed - to a specific file name in the installation folder of gbSIRTS. The text stereogram is saved to 'gbsirts_stereogram.bmp'. The depth mask is saved to 'gbsirts_depth.bmp'. gbSIRTS does not support saving the images to specific filenames/locations. Files are saved as .bmp only.

Also, when gbSIRTS is closed, the current custom depth mask is automatically saved to the file 'gbsirts_depth.bmp'. This same file is automatically read into gbSIRTS when it is started.

gbSIRTS can also save the stereogram image, stereogram text, or paint image to the clipboard.

Return to top of document

Paint Mode

gbSIRTS provides several basic functions which allow you to create you own depth masks. You can create a depth mask from scratch, or you can tweak an imported mask. When the "Paint Mode" toolbar button is pressed, the following frame is diplayed. The frame, along with context menu functions, provide all Paint functions.

Return to top of document

Toolbar Options

The following functions are available on the toolbar:


Return to top of document

Menu Options

gbSIRTS provides a Help menu, with the following selections.

When in SIRTS mode, the following context sensitive menu options are provided:

When in Paint mode, the following context sensitive menu options are provided:

Return to top of document

Change History