Skip to content

illusion

6 motifs. Import them from geomotif.motifs, or build one by name with registry.create("illusion.cafe-wall").

illusion.cafe-wall

illusion.cafe-wall

Parallel mortar lines that refuse to look parallel.

from geomotif import save_svg
from geomotif.motifs import CafeWall

motif = CafeWall()
save_svg(motif.build(), "illusion.cafe-wall.svg", width=320, height=320)
geomotif render illusion.cafe-wall --out illusion.cafe-wall.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.cafe-wall",
  "params": {
    "cols": 8,
    "rows": 6,
    "size": 40.0,
    "mortar": 3.0,
    "shift": 0.5,
    "hatch": 4,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default
cols int 8
rows int 6
size float 40.0
mortar float 3.0
shift float 0.5
hatch int 4
center Point (0.0, 0.0)

illusion.impossible-cube

illusion.impossible-cube

The same cube, told two contradictory things about which face is nearer.

from geomotif import save_svg
from geomotif.motifs import ImpossibleCube

motif = ImpossibleCube()
save_svg(motif.build(), "illusion.impossible-cube.svg", width=320, height=320)
geomotif render illusion.impossible-cube --out illusion.impossible-cube.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.impossible-cube",
  "params": {
    "size": 180.0,
    "depth": 0.45,
    "angle": 0.7853981633974483,
    "center": [
      0.0,
      0.0
    ],
    "gap": 0.06
  }
}
Parameters
Name Type Default
gap float 0.06
size float 180.0
depth float 0.45
angle float 0.7853981633974483
center Point (0.0, 0.0)

illusion.moire

illusion.moire

Two regular patterns laid over each other, and the fringes between them.

from geomotif import save_svg
from geomotif.motifs import MoirePattern

motif = MoirePattern(kind='rings')
save_svg(motif.build(), "illusion.moire.svg", width=320, height=320)
geomotif render illusion.moire --out illusion.moire.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.moire",
  "params": {
    "kind": "rings",
    "count": 34,
    "spacing": 6.0,
    "offset": 26.0,
    "angle": 0.06,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default
kind MoireKind 'rings'
count int 34
spacing float 6.0
offset float 26.0
angle float 0.06
center Point (0.0, 0.0)

illusion.necker-cube

illusion.necker-cube

A wireframe cube with nothing to say which face is in front.

from geomotif import save_svg
from geomotif.motifs import NeckerCube

motif = NeckerCube()
save_svg(motif.build(), "illusion.necker-cube.svg", width=320, height=320)
geomotif render illusion.necker-cube --out illusion.necker-cube.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.necker-cube",
  "params": {
    "size": 180.0,
    "depth": 0.45,
    "angle": 0.7853981633974483,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default
size float 180.0
depth float 0.45
angle float 0.7853981633974483
center Point (0.0, 0.0)

illusion.penrose-stairs

illusion.penrose-stairs

The endless staircase: four flights, every step up, back where you began.

from geomotif import save_svg
from geomotif.motifs import PenroseStairs

motif = PenroseStairs()
save_svg(motif.build(), "illusion.penrose-stairs.svg", width=320, height=320)
geomotif render illusion.penrose-stairs --out illusion.penrose-stairs.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.penrose-stairs",
  "params": {
    "steps": 5,
    "rise": 0.4,
    "width": 1.8,
    "size": 280.0,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default
steps int 5
rise float 0.4
width float 1.8
size float 280.0
center Point (0.0, 0.0)

illusion.penrose-triangle

illusion.penrose-triangle

The tribar: three square beams meeting at three right angles.

from geomotif import save_svg
from geomotif.motifs import PenroseTriangle

motif = PenroseTriangle()
save_svg(motif.build(), "illusion.penrose-triangle.svg", width=320, height=320)
geomotif render illusion.penrose-triangle --out illusion.penrose-triangle.svg
{
  "geomotif": "1.3.1",
  "motif": "illusion.penrose-triangle",
  "params": {
    "size": 240.0,
    "thickness": 0.25,
    "center": [
      0.0,
      0.0
    ]
  }
}
Parameters
Name Type Default
size float 240.0
thickness float 0.25
center Point (0.0, 0.0)