├── ch11 ├── example-11.1 │ ├── example.js │ └── example.html ├── example-11.3 │ ├── icon-ipad.png │ ├── startup-iphone.png │ ├── startup-iphone4.png │ ├── startup-iPad-portrait.png │ └── startup-iPad-landscape.png └── example-11.5 │ ├── icon-ipad.png │ ├── startup-iPad-portrait.png │ └── startup-iPad-landscape.png ├── shared └── images │ ├── sky.png │ ├── arch.png │ ├── bomb.png │ ├── camp.png │ ├── grass.png │ ├── tree.png │ ├── bucket.png │ ├── canyon.png │ ├── grass2.png │ ├── smalltree.png │ ├── waterfall.png │ ├── countrypath.jpg │ ├── curved-road.png │ ├── grand-canyon.png │ ├── log-crossing.png │ ├── lonelybeach.png │ ├── tree-twotrunks.png │ └── running-sprite-sheet.png ├── ch03 ├── example-3.2 │ ├── cloth.png │ ├── redball.png │ └── example.html ├── example-3.7 │ └── example.html ├── example-3.9 │ └── example.html ├── example-3.5 │ └── example.html ├── example-3.8 │ └── example.html ├── example-3.3 │ └── example.html ├── example-3.4 │ └── example.html ├── example-3.12 │ └── text.js └── example-3.1 │ └── example.html ├── ch09 ├── ungame │ ├── sounds │ │ ├── pop.mp3 │ │ ├── pop.ogg │ │ ├── whoosh.mp3 │ │ └── whoosh.ogg │ └── images │ │ ├── image1.png │ │ ├── image10.png │ │ ├── image11.png │ │ ├── image12.png │ │ ├── image2.png │ │ ├── image3.png │ │ ├── image4.png │ │ ├── image5.png │ │ ├── image6.png │ │ ├── image7.png │ │ ├── image8.png │ │ └── image9.png └── pinball │ ├── images │ ├── ball.png │ ├── tryAgain.png │ ├── actuator-0.png │ ├── actuator-1.png │ ├── actuator-2.png │ ├── actuator-3.png │ ├── actuator-4.png │ ├── actuator-5.png │ ├── actuator-6.png │ ├── actuator-7.png │ ├── background.png │ ├── leftFlipper.png │ ├── rightFlipper.png │ ├── fiftyBumperBright.png │ ├── pinball-withballs.png │ ├── fiveXBumperLeftBright.png │ ├── fiveXBumperRightBright.png │ ├── oneHundredBumperBright.png │ ├── oneXBumperLeftBright.png │ ├── oneXBumperRightBright.png │ ├── pinball-with-flippers.png │ ├── twoXBumperLeftBright.png │ ├── twoXBumperRightBright.png │ └── fiveHundredBumperBright.png │ └── sounds │ ├── bumper.ogg │ ├── flipper.ogg │ ├── jingle.mp3 │ ├── jingle.ogg │ ├── pinball.ogg │ └── ballRolling.ogg ├── ch02 ├── example-2.5 │ ├── redball.png │ └── example.html ├── example-2.12 │ ├── example.js │ └── example.html ├── example-2.1 │ ├── example.js │ └── example.html ├── example-2.3 │ ├── example.html │ └── example.js ├── example-2.2 │ ├── example.html │ └── example.js ├── example-2.4 │ ├── example.html │ └── example.js ├── example-2.20 │ └── example.html ├── example-2.17 │ ├── example.html │ └── example.js ├── example-2.22 │ ├── example.js │ └── example.html ├── section-2.13.2.3 │ └── example.html ├── example-2.18 │ └── example.html ├── example-2.13 │ ├── example.html │ └── example.js ├── example-2.14 │ └── example.html ├── example-2.24 │ └── example.html ├── example-2.9 │ └── example.html ├── example-2.21 │ └── example.html ├── example-2.35 │ └── example.html ├── example-2.11 │ └── example.html ├── example-2.23 │ └── example.html └── example-2.10 │ └── example.html ├── ch06 ├── example-6.10 │ ├── fuse-00.png │ ├── fuse-01.png │ ├── fuse-02.png │ ├── fuse-03.png │ ├── fuse-04.png │ ├── fuse-05.png │ ├── fuse-06.png │ ├── fuse-07.png │ ├── fuse-08.png │ ├── bomb-no-fuse.png │ ├── explosion-00.png │ ├── explosion-01.png │ ├── explosion-02.png │ ├── explosion-03.png │ ├── explosion-04.png │ ├── explosion-05.png │ ├── explosion-06.png │ ├── explosion-07.png │ └── explosion-08.png ├── example-6.5 │ ├── example.js │ └── example.html ├── example-6.1 │ └── example.html ├── example-6.9 │ └── example.html ├── example-6.2 │ └── example.html └── example-6.7 │ └── example.html ├── ch04 ├── example-4.1 │ ├── countrypath.jpg │ ├── example.js │ └── example.html ├── example-4.23 │ ├── README.txt │ ├── example.js │ └── example.html ├── example-4.25 │ └── README.txt ├── example-4.16 │ ├── sunglassFilter.js │ └── example.html ├── example-4.18 │ ├── sunglassFilter.js │ └── example.html ├── example-4.13 │ ├── example.js │ └── example.html ├── example-4.2 │ ├── example.html │ └── example.js ├── example-4.12 │ └── example.html ├── example-4.9 │ └── example.html ├── example-4.14 │ └── example.html ├── example-4.15 │ └── example.html ├── example-4.19 │ └── example.html └── example-4.20 │ └── example.html ├── ch08 ├── section-8.4.1.6 │ ├── golfball.png │ ├── tennis-ball.png │ └── example.html ├── example-8.8 │ └── example.html ├── example-8.19 │ └── example.html ├── example-8.1 │ └── example.html ├── example-8.10 │ └── example.html └── example-8.20 │ └── example.html ├── ch10 ├── example-10.10 │ └── pencilsAndBrush.jpg ├── example-10.4 │ └── example.js └── example-10.1 │ └── example.js ├── LICENSE.txt ├── ch01 ├── example-1.3 │ ├── example.js │ └── example.html ├── example-1.1 │ ├── example.js │ └── example.html ├── example-1.4 │ └── example.html ├── example-1.13 │ └── example.html ├── example-1.5 │ └── example.html └── example-1.11 │ └── example.html ├── ch07 └── example-7.5 │ └── example.html └── ch05 ├── example-5.12 └── example.html ├── example-5.17 └── example.html ├── example-5.15 └── example.html ├── example-5.11 └── example.html └── example-5.9 └── example.html /ch11/example-11.1/example.js: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /shared/images/sky.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/sky.png -------------------------------------------------------------------------------- /shared/images/arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/arch.png -------------------------------------------------------------------------------- /shared/images/bomb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/bomb.png -------------------------------------------------------------------------------- /shared/images/camp.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/camp.png -------------------------------------------------------------------------------- /shared/images/grass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/grass.png -------------------------------------------------------------------------------- /shared/images/tree.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/tree.png -------------------------------------------------------------------------------- /ch03/example-3.2/cloth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch03/example-3.2/cloth.png -------------------------------------------------------------------------------- /ch09/ungame/sounds/pop.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/sounds/pop.mp3 -------------------------------------------------------------------------------- /ch09/ungame/sounds/pop.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/sounds/pop.ogg -------------------------------------------------------------------------------- /shared/images/bucket.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/bucket.png -------------------------------------------------------------------------------- /shared/images/canyon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/canyon.png -------------------------------------------------------------------------------- /shared/images/grass2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/grass2.png -------------------------------------------------------------------------------- /ch02/example-2.5/redball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch02/example-2.5/redball.png -------------------------------------------------------------------------------- /ch03/example-3.2/redball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch03/example-3.2/redball.png -------------------------------------------------------------------------------- /ch09/pinball/images/ball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/ball.png -------------------------------------------------------------------------------- /shared/images/smalltree.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/smalltree.png -------------------------------------------------------------------------------- /shared/images/waterfall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/waterfall.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-00.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-01.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-02.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-03.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-04.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-05.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-06.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-07.png -------------------------------------------------------------------------------- /ch06/example-6.10/fuse-08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/fuse-08.png -------------------------------------------------------------------------------- /ch09/pinball/sounds/bumper.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/bumper.ogg -------------------------------------------------------------------------------- /ch09/pinball/sounds/flipper.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/flipper.ogg -------------------------------------------------------------------------------- /ch09/pinball/sounds/jingle.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/jingle.mp3 -------------------------------------------------------------------------------- /ch09/pinball/sounds/jingle.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/jingle.ogg -------------------------------------------------------------------------------- /ch09/pinball/sounds/pinball.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/pinball.ogg -------------------------------------------------------------------------------- /ch09/ungame/images/image1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image1.png -------------------------------------------------------------------------------- /ch09/ungame/images/image10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image10.png -------------------------------------------------------------------------------- /ch09/ungame/images/image11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image11.png -------------------------------------------------------------------------------- /ch09/ungame/images/image12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image12.png -------------------------------------------------------------------------------- /ch09/ungame/images/image2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image2.png -------------------------------------------------------------------------------- /ch09/ungame/images/image3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image3.png -------------------------------------------------------------------------------- /ch09/ungame/images/image4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image4.png -------------------------------------------------------------------------------- /ch09/ungame/images/image5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image5.png -------------------------------------------------------------------------------- /ch09/ungame/images/image6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image6.png -------------------------------------------------------------------------------- /ch09/ungame/images/image7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image7.png -------------------------------------------------------------------------------- /ch09/ungame/images/image8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image8.png -------------------------------------------------------------------------------- /ch09/ungame/images/image9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/images/image9.png -------------------------------------------------------------------------------- /ch09/ungame/sounds/whoosh.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/sounds/whoosh.mp3 -------------------------------------------------------------------------------- /ch09/ungame/sounds/whoosh.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/ungame/sounds/whoosh.ogg -------------------------------------------------------------------------------- /ch11/example-11.3/icon-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.3/icon-ipad.png -------------------------------------------------------------------------------- /ch11/example-11.5/icon-ipad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.5/icon-ipad.png -------------------------------------------------------------------------------- /shared/images/countrypath.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/countrypath.jpg -------------------------------------------------------------------------------- /shared/images/curved-road.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/curved-road.png -------------------------------------------------------------------------------- /shared/images/grand-canyon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/grand-canyon.png -------------------------------------------------------------------------------- /shared/images/log-crossing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/log-crossing.png -------------------------------------------------------------------------------- /shared/images/lonelybeach.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/lonelybeach.png -------------------------------------------------------------------------------- /ch04/example-4.1/countrypath.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch04/example-4.1/countrypath.jpg -------------------------------------------------------------------------------- /ch08/section-8.4.1.6/golfball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch08/section-8.4.1.6/golfball.png -------------------------------------------------------------------------------- /ch09/pinball/images/tryAgain.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/tryAgain.png -------------------------------------------------------------------------------- /shared/images/tree-twotrunks.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/tree-twotrunks.png -------------------------------------------------------------------------------- /ch06/example-6.10/bomb-no-fuse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/bomb-no-fuse.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-00.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-01.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-02.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-03.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-04.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-05.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-06.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-07.png -------------------------------------------------------------------------------- /ch06/example-6.10/explosion-08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch06/example-6.10/explosion-08.png -------------------------------------------------------------------------------- /ch08/section-8.4.1.6/tennis-ball.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch08/section-8.4.1.6/tennis-ball.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-0.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-1.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-2.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-3.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-4.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-5.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-6.png -------------------------------------------------------------------------------- /ch09/pinball/images/actuator-7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/actuator-7.png -------------------------------------------------------------------------------- /ch09/pinball/images/background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/background.png -------------------------------------------------------------------------------- /ch09/pinball/images/leftFlipper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/leftFlipper.png -------------------------------------------------------------------------------- /ch09/pinball/images/rightFlipper.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/rightFlipper.png -------------------------------------------------------------------------------- /ch09/pinball/sounds/ballRolling.ogg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/sounds/ballRolling.ogg -------------------------------------------------------------------------------- /ch11/example-11.3/startup-iphone.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.3/startup-iphone.png -------------------------------------------------------------------------------- /ch10/example-10.10/pencilsAndBrush.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch10/example-10.10/pencilsAndBrush.jpg -------------------------------------------------------------------------------- /ch11/example-11.3/startup-iphone4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.3/startup-iphone4.png -------------------------------------------------------------------------------- /shared/images/running-sprite-sheet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/shared/images/running-sprite-sheet.png -------------------------------------------------------------------------------- /ch09/pinball/images/fiftyBumperBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/fiftyBumperBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/pinball-withballs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/pinball-withballs.png -------------------------------------------------------------------------------- /ch11/example-11.3/startup-iPad-portrait.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.3/startup-iPad-portrait.png -------------------------------------------------------------------------------- /ch11/example-11.5/startup-iPad-portrait.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.5/startup-iPad-portrait.png -------------------------------------------------------------------------------- /ch09/pinball/images/fiveXBumperLeftBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/fiveXBumperLeftBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/fiveXBumperRightBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/fiveXBumperRightBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/oneHundredBumperBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/oneHundredBumperBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/oneXBumperLeftBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/oneXBumperLeftBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/oneXBumperRightBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/oneXBumperRightBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/pinball-with-flippers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/pinball-with-flippers.png -------------------------------------------------------------------------------- /ch09/pinball/images/twoXBumperLeftBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/twoXBumperLeftBright.png -------------------------------------------------------------------------------- /ch09/pinball/images/twoXBumperRightBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/twoXBumperRightBright.png -------------------------------------------------------------------------------- /ch11/example-11.3/startup-iPad-landscape.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.3/startup-iPad-landscape.png -------------------------------------------------------------------------------- /ch11/example-11.5/startup-iPad-landscape.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch11/example-11.5/startup-iPad-landscape.png -------------------------------------------------------------------------------- /ch09/pinball/images/fiveHundredBumperBright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/corehtml5canvas/code/HEAD/ch09/pinball/images/fiveHundredBumperBright.png -------------------------------------------------------------------------------- /ch04/example-4.23/README.txt: -------------------------------------------------------------------------------- 1 | Due to copyright restrictions, you need to put your own video file in this directory, and reference it in example.html for this example to work. 2 | -------------------------------------------------------------------------------- /ch04/example-4.25/README.txt: -------------------------------------------------------------------------------- 1 | Due to copyright restrictions, you need to put your own video file in this directory, and reference it in example.html for this example to work. 2 | -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | Copyright (C) 2012 David Geary. 2 | 3 | This code is from the book Core HTML5 Canvas, published by Prentice-Hall in 2012. 4 | 5 | License: 6 | 7 | Permission is hereby granted, free of charge, to any person 8 | obtaining a copy of this software and associated documentation files 9 | (the "Software"), to deal in the Software without restriction, 10 | including without limitation the rights to use, copy, modify, merge, 11 | publish, distribute, sublicense, and/or sell copies of the Software, 12 | and to permit persons to whom the Software is furnished to do so, 13 | subject to the following conditions: 14 | 15 | The above copyright notice and this permission notice shall be 16 | included in all copies or substantial portions of the Software. 17 | 18 | The Software may not be used to create training material of any sort, 19 | including courses, books, instructional videos, presentations, etc. 20 | without the express written consent of David Geary. 21 | 22 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 23 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 24 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 25 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 26 | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 28 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 29 | OTHER DEALINGS IN THE SOFTWARE. 30 | 31 | -------------------------------------------------------------------------------- /ch04/example-4.1/example.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2012 David Geary. This code is from the book 3 | * Core HTML5 Canvas, published by Prentice-Hall in 2012. 4 | * 5 | * License: 6 | * 7 | * Permission is hereby granted, free of charge, to any person 8 | * obtaining a copy of this software and associated documentation files 9 | * (the "Software"), to deal in the Software without restriction, 10 | * including without limitation the rights to use, copy, modify, merge, 11 | * publish, distribute, sublicense, and/or sell copies of the Software, 12 | * and to permit persons to whom the Software is furnished to do so, 13 | * subject to the following conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * The Software may not be used to create training material of any sort, 19 | * including courses, books, instructional videos, presentations, etc. 20 | * without the express written consent of David Geary. 21 | * 22 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 23 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 24 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 25 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 26 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 28 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 29 | * OTHER DEALINGS IN THE SOFTWARE. 30 | */ 31 | 32 | var canvas = document.getElementById('canvas'), 33 | context = canvas.getContext('2d'), 34 | image = new Image(); 35 | 36 | image.src = '../../shared/images/countrypath.jpg'; 37 | image.onload = function(e) { 38 | context.drawImage(image, 0, 0); 39 | }; 40 | -------------------------------------------------------------------------------- /ch02/example-2.12/example.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2012 David Geary. This code is from the book 3 | * Core HTML5 Canvas, published by Prentice-Hall in 2012. 4 | * 5 | * License: 6 | * 7 | * Permission is hereby granted, free of charge, to any person 8 | * obtaining a copy of this software and associated documentation files 9 | * (the "Software"), to deal in the Software without restriction, 10 | * including without limitation the rights to use, copy, modify, merge, 11 | * publish, distribute, sublicense, and/or sell copies of the Software, 12 | * and to permit persons to whom the Software is furnished to do so, 13 | * subject to the following conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * The Software may not be used to create training material of any sort, 19 | * including courses, books, instructional videos, presentations, etc. 20 | * without the express written consent of David Geary. 21 | * 22 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 23 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 24 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 25 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 26 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 28 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 29 | * OTHER DEALINGS IN THE SOFTWARE. 30 | */ 31 | 32 | var context = document.getElementById('canvas').getContext('2d'); 33 | 34 | context.lineWidth = 1; 35 | context.beginPath(); 36 | context.moveTo(50, 10); 37 | context.lineTo(450, 10); 38 | context.stroke(); 39 | 40 | context.beginPath(); 41 | context.moveTo(50.5, 50.5); 42 | context.lineTo(450.5, 50.5); 43 | context.stroke(); 44 | -------------------------------------------------------------------------------- /ch02/example-2.1/example.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (C) 2012 David Geary. This code is from the book 3 | * Core HTML5 Canvas, published by Prentice-Hall in 2012. 4 | * 5 | * License: 6 | * 7 | * Permission is hereby granted, free of charge, to any person 8 | * obtaining a copy of this software and associated documentation files 9 | * (the "Software"), to deal in the Software without restriction, 10 | * including without limitation the rights to use, copy, modify, merge, 11 | * publish, distribute, sublicense, and/or sell copies of the Software, 12 | * and to permit persons to whom the Software is furnished to do so, 13 | * subject to the following conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * The Software may not be used to create training material of any sort, 19 | * including courses, books, instructional videos, presentations, etc. 20 | * without the express written consent of David Geary. 21 | * 22 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 23 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 24 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 25 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 26 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 27 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 28 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 29 | * OTHER DEALINGS IN THE SOFTWARE. 30 | */ 31 | 32 | var canvas = document.getElementById('canvas'), 33 | context = canvas.getContext('2d'); 34 | 35 | context.lineWidth = 30; 36 | 37 | context.font = '24px Helvetica'; 38 | context.fillText('Click anywhere to erase', 175, 40); 39 | 40 | context.strokeRect(75, 100, 200, 200); 41 | context.fillRect(325, 100, 200, 200); 42 | 43 | context.canvas.onmousedown = function (e) { 44 | context.clearRect(0, 0, canvas.width, canvas.height); 45 | }; 46 | -------------------------------------------------------------------------------- /ch02/example-2.3/example.html: -------------------------------------------------------------------------------- 1 | 2 | 32 | 33 |
34 |