I know this is an old thread but it might be useful for some people such as myself that months after are hitting this issue for the first time.
Here is some code that resizes the image every time you reload the image. I am aware this is not optimal at all, but I provide it as a proof of concept.
Also, sorry for using jQuery for simple selectors but I just feel too comfortable with the syntax.
$(document).on('ready', createImage);_x000D_
$(window).on('resize', createImage);_x000D_
_x000D_
var createImage = function(){_x000D_
var canvas = document.getElementById('myCanvas');_x000D_
canvas.width = window.innerWidth || $(window).width();_x000D_
canvas.height = window.innerHeight || $(window).height();_x000D_
var ctx = canvas.getContext('2d');_x000D_
img = new Image();_x000D_
img.addEventListener('load', function () {_x000D_
ctx.drawImage(this, 0, 0, w, h);_x000D_
});_x000D_
img.src = 'http://www.ruinvalor.com/Telanor/images/original.jpg';_x000D_
};
_x000D_
html, body{_x000D_
height: 100%;_x000D_
width: 100%;_x000D_
margin: 0;_x000D_
padding: 0;_x000D_
background: #000;_x000D_
}_x000D_
canvas{_x000D_
position: absolute;_x000D_
left: 0;_x000D_
top: 0;_x000D_
z-index: 0;_x000D_
}
_x000D_
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>_x000D_
<html>_x000D_
<head>_x000D_
<meta charset="utf-8" />_x000D_
<title>Canvas Resize</title>_x000D_
</head>_x000D_
<body>_x000D_
<canvas id="myCanvas"></canvas>_x000D_
</body>_x000D_
</html>
_x000D_
My createImage function is called once when the document is loaded and after that it is called every time the window receives a resize event.
I tested it in Chrome 6 and Firefox 3.6, both on the Mac. This "technique" eats processor as it if was ice cream in the summer, but it does the trick.