Today's Retrofuturism is the fusion of photographic film and a webcam to create a realtime negative viewer.

Inspired by K Lars Lohn on Mastodon, I have been culling physical media.

Positive images like slides and prints are easy to sort through. Negative images aren't quite as easy. Because scanning takes a minute or more per frame, I didn't want to do that to every frame. A negative viewer like the xray viewers in cartoons would have been wonderful. So I created one.

I turned to OpenCV and Python to write a basic realtime negative viewer using a webcam, a cheap lightbox, and a script.

It turned out to be as simple as installing cv2 and a few lines of code.

pip install opencv-python

And this little script:

import cv2

window = 'Negative Viewer'
device = 0

cv2.namedWindow(window)
cap = cv2.VideoCapture(device)

while True:
    ret, frame = cap.read()
    if not ret:
        break

    cv2.imshow(window, cv2.bitwise_not(frame))

    # Break the loop if 'q' is pressed
    key_code = cv2.waitKey(1)
    key = bytes([key_code & 0xff]).decode(errors='ignore')

    if key in ('q', 'Q'):
        break

Enjoy.