# Stereoscopy
## Introduction

In this learning resource we will create a 3D perception from two separtes standard images and create again an image that can be used in a head mounted display to view the 3D scene. All methods should be replicable with low cost IT infrastructure or just you smartphone and application OpenSource software.

## Major Steps

* (Left Eye - Right Eye) Create two different images for the left eye and for the right eye and learn how to create the images with different methods.
* (Positioning of Images for Eyes) If images are take without a tripod, the positioning of objects on the image might not be correct. This step shows how to align the left and right image.
* combine the two images in own image and add a mask to the image
* Extend the concept to the recording of 3D videos with two action cams mounted with a parallel view in the distance your eyes
* (Geometry) Usage of stereoscopy in Geometry and Photogrammetry
* (Background) Analyze the historic background of Stereoscopy and explain how the knowledge can be used to understand the foundation of Virtual Reality and Augmented Reality.

## Introduction

Stereoscopy (also called stereoscopics, or stereo imaging) is a technique for creating or enhancing the illusion of depth in an image by means of stereopsis for binocular vision. The word stereoscopy derives form the greek language from στερεός (stereos) which means firm, solid and σκοπέω (skopeō) for to look, to see. Any stereoscopic image is called a stereogram. Originally, stereogram referred to a pair of stereo images which could be viewed using a stereoscope.
Most stereoscopic methods present two offset images separately to the left and right eye of the viewer. These two-dimensional images are then combined in the brain to give the perception of 3D depth. This technique is distinguished from 3D displays that display an image in three full dimensions, allowing the observer to increase information about the 3-dimensional objects being displayed by head and eye movements.

### VR-Headset with Smartphone

If you have a VR headset for smartphones insert the smartphone and test the stereoscopy images in that headset. For this learning resource a WebApp Stereoscopy4Broswer on GitHub was created for testing the stereoscopic images in VR headsets for smartphones in split screen with immersive fullscreen display of images.

### Source Images for left and right eye

| Image for left eye | Image for right eye |

### Transparent Alignment of Images

The alignment of the individual images for the left and right eye may be necessary if the individual images were taken freehand with a single camera and a horizontal shift of the individual images in the distance of the eye. The following animation shows the positioning of the individual images for a single point on the front edge of the table as reference point. The individual images are aligned by placing a fixed reference point at the same position in both individual images.

### Stereoscopy Image in VR Headset
## Learning Tasks

* (3D Modelling) Analyze how 3D Modelling with AR.js and Aframe uses the principle of Stereoscopy to create 3D view for generate scene.
* (Position of Eyes) Close your right eye and then the left eye quickly one after another and compare the images you view just with one eye. Can you identify animals that are able of 3D perception (e.g. an owl) and can you explain why evolution "placed" the eyes more on the side of the head (e.g. for horses) to have a more or less 360-degree view for predators.
* (LibreOffice Draw - LR-Mask) Start the LibreOffice demo file with the LR-mask (Left-Right eye mask) and place the two images for the left eye under the left part of the eye and right image under the part of the eye.
* (Generation of AppLSAC) Create a WebApp that allows you to align a left eye and a right eye image to create stereoscopic images.