Steal Nick Cage Face Canvas
view-source:http://adamusprime.tumblr.com/niccagehead
by paullferguson
HTML
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>XP GUSTA</title>
<style type="text/css">
body {
background-color: #ffffff;
margin: 0px;
cursor: none;
overflow: hidden;
}
</style>
<meta http-equiv="x-dns-prefetch-control" content="off"/></head>
<body>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-8119996-1']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
<script type="text/javascript">
var imageWidthHalf, imageHeightHalf;
var canvas = document.createElement( 'canvas' );
canvas.width = window.innerWidth;
canvas.height = window.innerHeight;
canvas.style.display = 'block';
document.body.appendChild( canvas );
var context = canvas.getContext( '2d' );
var image = document.createElement( 'img' );
image.addEventListener('load', function() {
imageWidthHalf = Math.floor( this.width / 2 );
imageHeightHalf = Math.floor( this.height / 2 );
document.addEventListener( 'mousemove', onMouseEvent, false );
document.addEventListener( 'touchstart', onTouchEvent, false );
document.addEventListener( 'touchmove', onTouchEvent, false );
}, false );
image.src = "http://www.paul-ferguson.co.uk/dump/zombie-paul.png";
function onMouseEvent( event ) {
...