Skip to content

A Javascript implementation for showing anaglyph and interlaced 3D images from side-by-side source images

Notifications You must be signed in to change notification settings

Timendus/three-dimensional-image

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

3D images in Javascript

A Javascript implementation for showing anaglyph and interlaced 3D images from side-by-side source images.

Create a 3D image from a specific image:

image = new threeDimensionalImage(document.querySelector("img#my-3d-image"));

3D-ify all image elements with attribute data-type='3d-sbs':

var images = document.querySelectorAll("img[data-type='3d-sbs']");
Array.prototype.forEach.call(images, function(el, i){
  new threeDimensionalImage(el);
});

To undo:

image.dismiss();

About

A Javascript implementation for showing anaglyph and interlaced 3D images from side-by-side source images

Resources

Stars

Watchers

Forks