I would simply start by replacing LoadImage with this: BABYLON.Tools.LoadImage = function(url, onload, onerror, database) {          var img = new Image();     var xhr = new XMLHttpRequest();     //replace this with the headers you want to set     //xhr.setRequestHeader("[KEY]", "[VALUE]");     xhr.open("GET", url);     xhr.responseType = "blob";     xhr.onload = function() {       img.src = window.URL.createObjectURL(xhr.response);     }     xhr.send();