Sunday, June 14, 2026
HomeLanguagesWand stereogram() function in Python

Wand stereogram() function in Python

Stereogram Effect is the effect that generates image inside image. A stereogram is a picture within a picture. Hidden inside each image is an object which appears in 3D when viewed correctly.
stereogram() function takes two Image instances (one for each eye), and creates a 3d image by separating the Red & Cyan.

Syntax :

wand.image.stereogram(left, right)

Parameters :

Parameter Input Type Description
left wand.image.Image() Left-eye image.
right wand.image.Image() Right-eye image.

Source Image:

Example 1:




# Import Image from wand.image module
from wand.image import Image
  
# Read image using Image function
with Image(filename ="koala.jpeg") as leftimg:
  
    with Image(filename ="koala.jpeg") as rightimg:
        # stereogram image using stereogram function
        with Image.stereogram(left = leftimg, right = rightimg) as img:
            img.save(filename ="fx-stereogram.jpg")


Output:

Source Image:

Example 2:




# Import Image from wand.image module
from wand.image import Image
  
# Read image using Image function
with Image(filename ="koala.jpeg") as leftimg:
  
    with Image(filename ="koala.jpeg") as rightimg:
  
        # stereogram image using stereogram function
        with Image.stereogram(left = leftimg, right = rightimg) as img:
            img.save(filename ="fx-stereogram.jpg")


Output:

Dominic
Dominichttp://wardslaus.com
infosec,malicious & dos attacks generator, boot rom exploit philanthropist , wild hacker , game developer,
RELATED ARTICLES

Most Popular

Dominic
32515 POSTS0 COMMENTS
Milvus
131 POSTS0 COMMENTS
Nango Kala
6897 POSTS0 COMMENTS
Nicole Veronica
12013 POSTS0 COMMENTS
Nokonwaba Nkukhwana
12109 POSTS0 COMMENTS
Shaida Kate Naidoo
7019 POSTS0 COMMENTS
Ted Musemwa
7262 POSTS0 COMMENTS
Thapelo Manthata
6976 POSTS0 COMMENTS
Umr Jansen
6964 POSTS0 COMMENTS