demos/Collage/fabric.js
function (url, callback) { // TODO (kangax): test callback
      fabric.util.loadImage(url, function(img) {
        this.overlayImage = img;
        callback && callback();
      }, this);
      return this;
    }
function (url, callback) { // TODO (kangax): test callback
      fabric.util.loadImage(url, function(img) {
        this.overlayImage = img;
        callback && callback();
      }, this);
      return this;
    }
function ( url , callback ) { // TODO (kangax): test callback fabric . util . loadImage ( url , function ( img ) { this . overlayImage = img ; callback && callback ( ) ; } , this ) ; return this ; }
Sets overlay image for this canvas
@method setOverlayImage
@param {String} url url of an image to set overlay to
@param {Function} callback callback to invoke when image is loaded and set as an overlay
@return {fabric.Canvas} thisArg
@chainable
Sets overlay image for this canvas