Tempusxr Français
Menu
  1. Docs
  2. Image tracking examples

Summary

Seven small examples show the main features of image tracking. Each one comes twice, as an A-Frame page (HTML only) and as a Three.js page (JavaScript), so you can compare and pick your style. The code on each page is the code of the demo, read from the file.

How to try them

  1. Open the demo on a phone, over the secure address of this site: the camera needs it.
  2. Show the picture of the example to the camera. Put it on a second screen, or print it. Tap a picture on its page to open it full size.
  3. Add ?debug to the address to see frame rates and phone facts.

The examples

ExampleWhat it showsPicture to point at
MinimalThe smallest page: one image, one box.poster.png
BasicA veil with the proportions of the image and an animated shape.poster.png
Multi-targetsSeveral images in one file, different content on each, one followed at a time.card.png, poster.png, art.png
Multi-tracksSeveral images followed at the same time, with a counter.two of the three pictures together
Custom UIYour own interface in HTML above the camera.poster.png
Events handlingThe camera, found and lost events, printed on screen.poster.png
InteractiveTap the 3D objects: change a color, make a ball jump.poster.png

Finished experiences

Larger examples built the same way. Each has the picture to point at in its own folder.

ExampleWhat it doesStack
Business cardCall, email and website buttons appear on the card.A-Frame
Poster with videoA video plays on the poster, with a sound button.A-Frame
Picture frameA 3D frame fits the painting, and a button changes its style.A-Frame
Tree in a frameA frame appears and a 3D tree grows inside it.Three.js
Plan to roomThe rooms and the furniture rise from a floor plan.Three.js

The pictures: card, poster, painting, tree and floor plan.

Make your own target file

All examples load a .txr file made from their pictures. Make yours with the image compiler.