I’m having issues with TextureLoader
Books.prototype.initMaterials = function() {
var self = this;
self.materials = [];
var $textureImgEls = $("#textures .texture");
$textureImgEls.each(function() {
//var texture = THREE.ImageUtils.loadTexture(this.src);
var texture =new THREE.TextureLoader();
texture.load(this.src);
self.materials.push(new THREE.MeshLambertMaterial({map: texture}));
// this.addEventListener("click", function(){ alert("Hello World!")});
// console.log(this.src);
//imgs.push(this.src);
});
// console.log(imgs);
};
Error: 41 Uncaught TypeError: Cannot read property 'load' of undefined