C H A P T E R  8

Jigsaw Video: Using the Mouse and Touch to Arrange Images

In this chapter, you will learn the following:

  • How to set up mouse and touch events to build an application to work on a variety of devices
  • Ways to break up a picture into pieces and determine the coordinates for those pieces to produce a jigsaw puzzle
  • How to calculate horizontal and vertical coordinates and manipulate left and top style attributes to reposition elements on the screen
  • About the concept of tolerance or margin so your player does not have to be perfect to solve the puzzle
  • How to make the jigsaw turn into a running video

Get HTML5 and JavaScript Projects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.